-
Hi, In a server Action I operate on the source model (it adjusts the position of many elements). So after finishing this I need a complete refresh on the client side. My code looks currently like this: public class BPMNResetRoutingActionHandler extends AbstractActionHandler<BPMNResetRoutingAction> {
@Inject
protected BPMNGModelState modelState;
@Override
protected List<Action> executeAction(final BPMNResetRoutingAction actualAction) {
// update source model.....
................
// Force a complete refresh of the GModel state....
modelState.refreshGModelState(); // Full rebuild of the GModel and update the root element of my GModelState
List<Action> resultAction = new ArrayList<>();
resultAction.add(new SetDirtyStateAction(true, SetDirtyStateAction.Reason.OPERATION));
resultAction.add(new UpdateModelAction(modelState.getRoot()));
return resultAction;
}
} I do:
With less code it does not work. What would be the 'normal' way to tell the client to rerender the complete model? |
Beta Was this translation helpful? Give feedback.
Answered by
rsoika
Feb 13, 2024
Replies: 1 comment
-
Ah.... maybe I found the solution by myself.
It looks that this solves my problem. No more need to care about DirtyStates and UpdateModelActions.... |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
tortmayr
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Ah.... maybe I found the solution by myself.
Action
but anOperation
AbstractActionHandler
but aGModelOperationHandler
It looks that this solves my problem. No more need to care about DirtyStates and UpdateModelActions....