public class DefinitionResolver extends Object
Because the Stunner model aggregates different aspects of a node, while the Eclipse model keeps them in separate sections, we use this object to access such aspects, namely
signal concern is due to a bug in current Eclipse BPMN2 implementation, which is outdated w.r.t. upstream.
| Constructor and Description |
|---|
DefinitionResolver(Definitions definitions,
Collection<WorkItemDefinition> workItemDefinitions) |
DefinitionResolver(Definitions definitions,
Collection<WorkItemDefinition> workItemDefinitions,
boolean jbpm,
MarshallingRequest.Mode mode) |
| Modifier and Type | Method and Description |
|---|---|
Definitions |
getDefinitions() |
BPMNDiagram |
getDiagram() |
BPMNEdge |
getEdge(String elementId) |
MarshallingRequest.Mode |
getMode() |
Process |
getProcess() |
double |
getResolutionFactor() |
BPMNShape |
getShape(String elementId) |
Collection<WorkItemDefinition> |
getWorkItemDefinitions() |
boolean |
isJbpm() |
Optional<Signal> |
resolveSignal(String id)
A helper method to return a Signal instance for a given Signal ID.
|
String |
resolveSignalName(String id)
A utility to return Signal#getName for a given Signal ID.
|
Optional<ElementParameters> |
resolveSimulationParameters(String id)
Returns the simulation parameters attached to a given ID
|
public DefinitionResolver(Definitions definitions, Collection<WorkItemDefinition> workItemDefinitions, boolean jbpm, MarshallingRequest.Mode mode)
public DefinitionResolver(Definitions definitions, Collection<WorkItemDefinition> workItemDefinitions)
public BPMNDiagram getDiagram()
public double getResolutionFactor()
public boolean isJbpm()
public Definitions getDefinitions()
public Process getProcess()
public MarshallingRequest.Mode getMode()
public Collection<WorkItemDefinition> getWorkItemDefinitions()
public Optional<Signal> resolveSignal(String id)
The reason we only have Signal resolution and we do not have Message, Error, Timer resolution, is that Message, Error, Timer instances are usually attached to the events that refer them, so that we can do:
Message mySignal = myEvent.getMessageRef()
this isn't so for Signal, due to a bug in the method signature/impl.
getSignalRef() actually returns the reference (the String ID)
to the Signal instead of resolving it to the Signal instnace.
This method can be safely dropped as soon as we find a way to upgrade the underlying BPMN2 Eclipse parser without breaking the rest of the code base.
public String resolveSignalName(String id)
public Optional<ElementParameters> resolveSimulationParameters(String id)
Copyright © 2001–2021 JBoss by Red Hat. All rights reserved.