Interface StateMachineDiagramEditor
- All Superinterfaces:
BasicDiagramEditor,BehaviorDiagramEditor,DiagramEditor
Interface to create presentations in Statemachine Diagram.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddRegion(INodePresentation parent, boolean isHorizontal) Add a region in a parent presentation.voidchangeParentOfState(INodePresentation child, INodePresentation parent) Change a parent of a state or a pseudostate.createChoicePseudostate(INodePresentation parent, Point2D location) Create a choice pseudostate.createDeepHistoryPseudostate(INodePresentation parent, Point2D location) Create a deep history Pseudostate.createFinalState(INodePresentation parent, Point2D location) Create a final state.createForkPseudostate(INodePresentation parent, Point2D location, double width, double height) Create a fork pseudostate.createInitialPseudostate(INodePresentation parent, Point2D location) Create an initial pseudostate.createJoinPseudostate(INodePresentation parent, Point2D location, double width, double height) Create a Join Pseudostate.createJunctionPseudostate(INodePresentation parent, Point2D location) Create a junction pseudostate.createShallowHistoryPseudostate(INodePresentation parent, Point2D location) Create a shallow history Pseudostate.createState(String name, INodePresentation parent, Point2D location) Create a state in a parent presentation.createStatemachineDiagram(INamedElement owner, String name) Crate a statemachine diagram in a parent package.createSubmachineState(INodePresentation parent, IStateMachineDiagram submachine, Point2D location) Create a submachine state.createTransition(INodePresentation source, INodePresentation target) Create a transition.voiddeleteRegion(INodePresentation parent, int index) Delete a region in a parent presentation.Methods inherited from interface com.change_vision.jude.api.inf.editor.BasicDiagramEditor
createNote, createNoteAnchor, createNoteAnchorMethods inherited from interface com.change_vision.jude.api.inf.editor.DiagramEditor
createImage, createImage, createLine, createRect, createText, delete, deleteDiagram, deletePresentation, getDiagram, setDiagram
-
Method Details
-
createStatemachineDiagram
Crate a statemachine diagram in a parent package. Diagram is set to DiagramEditor (DiagramEditor.setDiagram(IDiagram diagram)) if the diagram is created successfully.- Parameters:
owner- Parent Packagename- Statemachine Diagram Name- Returns:
- Statemachine Diagram
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_NAME_ERROR_KEY - if the name is empty. ILLEGALMODELTYPE_ERROR_KEY - if the model type is illegal. READ_ONLY_KEY - if a read-only element is edited. INVALID_OWNER_KEY - if the owner is invalid. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createState
Create a state in a parent presentation.- Parameters:
name- State Nameparent- Parent Presentationlocation- Location- Returns:
- INodePresentation State
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_NAME_ERROR_KEY - if the name is empty. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
addRegion
Add a region in a parent presentation.- Parameters:
parent- Parent PresentationisHorizontal- is Horizontal.- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_NAME_ERROR_KEY - if the name is empty. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.- Since:
- 6.6.4
-
deleteRegion
Delete a region in a parent presentation.- Parameters:
parent- Parent Presentationindex- region index- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_NAME_ERROR_KEY - if the name is empty. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.- Since:
- 6.6.4
-
createInitialPseudostate
Create an initial pseudostate.- Parameters:
parent- Parent Presentationlocation- Location- Returns:
- INodePresentation InitialPseudostate
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createFinalState
Create a final state.- Parameters:
parent- Parent Presentationlocation- Location- Returns:
- INodePresentation FinalState
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createChoicePseudostate
Create a choice pseudostate.- Parameters:
parent- Parent Presentationlocation- Location- Returns:
- INodePresentation ChoicePseudostate
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createJunctionPseudostate
Create a junction pseudostate.- Parameters:
parent- Parent Presentationlocation- Location- Returns:
- INodePresentation
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createForkPseudostate
INodePresentation createForkPseudostate(INodePresentation parent, Point2D location, double width, double height) Create a fork pseudostate.- Parameters:
parent- parent Presentationlocation- locationwidth- widthheight- height- Returns:
- INodePresentation
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createJoinPseudostate
INodePresentation createJoinPseudostate(INodePresentation parent, Point2D location, double width, double height) Create a Join Pseudostate.- Parameters:
parent- Parent Presentationlocation- Locationwidth- Widthheight- Height- Returns:
- INodePresentation
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createShallowHistoryPseudostate
Create a shallow history Pseudostate.- Parameters:
parent- Parent Presentationlocation- Location- Returns:
- INodePresentation
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. DUPLICATED_HISTORY_KEY - if a history already exists in a diagram or a composite state. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createDeepHistoryPseudostate
Create a deep history Pseudostate.- Parameters:
parent- Parent Presentationlocation- Location- Returns:
- INodePresentation
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. DUPLICATED_HISTORY_KEY - if a history already exists in a diagram or a composite state. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createSubmachineState
INodePresentation createSubmachineState(INodePresentation parent, IStateMachineDiagram submachine, Point2D location) Create a submachine state.- Parameters:
parent- Parent Presentationsubmachine- Submachine- Returns:
- INodePresentation
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. SAME_DIAGRAM_ERROR_KEY - if a SubmachineState is created in the same diagram. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. INVALID_PARENT_KEY - if the parent is invalid. READ_ONLY_KEY - if a read-only element is edited. OUT_OF_CONTAINER_KEY - if the location is specified out of container. LOCATION_ERROR_KEY - if a parent exists in the specified location. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
createTransition
Create a transition.- Parameters:
source- Sourcetarget- Target- Returns:
- ILinkPresentation Transition
- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. INVALID_DIAGRAM_ERROR_KEY - if a diagram of an element is not correct. READ_ONLY_KEY - if a read-only element is edited. INVALID_SOURCE_KEY - if a source of a relation is invalid. INVALID_TARGET_KEY - if a target of a relation is invalid. SELF_RELATION_KEY - if the self relationship is not allowed. DUPLICATED_OUTGOING_KEY - if duplicated outgoings are set. DUPLICATED_INCOMING_KEY - if duplicated incomings are set. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.
-
changeParentOfState
Change a parent of a state or a pseudostate.- Parameters:
child- Target presentation to changeparent- Parent presentation, null for just in diagram- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: PARAMETER_ERROR_KEY - if a parameter is not set properly. NO_TARGET_DIAGRAM_KEY - if target Diagram is not set. ILLEGAL_DIAGRAM_TYPE_KEY - if the diagram type is illegal. READ_ONLY_KEY - if a read-only element is edited. INVALID_PARENT_KEY - if the parent is invalid. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred.Values: Error messages for exceptions.- Since:
- 6.7
-