Interface IElement
- All Superinterfaces:
IEntity
- All Known Subinterfaces:
IAccident,IAccidentHazardSafetyConstraintTable,IAction,IActivity,IActivityDiagram,IActivityNode,IActivityParameterNode,IArgumentAsset,IArgumentationElement,IArtifact,IAssociation,IAssociationClass,IAssumption,IAttribute,IBindingConnector,IBlock,IBlockDefinitionDiagram,IClass,IClassDiagram,IClassifierTemplateParameter,ICombinedFragment,IComment,IComponent,IComponent,ICompositeStructureDiagram,IConnector,IConstraint,IConstraintBlock,IConstraintParameter,IConstraintProperty,IContext,IControlAction,IControlLink,IControlLoopDiagram,IControlNode,IControlStructureDiagram,ICountermeasure,ICountermeasureTable,IDataType,IDependency,IDiagram,IDurationConstraint,IEnumeration,IEnumerationLiteral,IEnumerationValueType,IExtend,IExtentionPoint,IFeedback,IFeedbackLink,IFinalState,IFlow,IFlowProperty,IGate,IGeneralization,IGoal,IGsnDiagram,IGsnElement,IHazard,IHazardCausalFactor,IHazardScenario,IIdentifiedElement,IInclude,IInContextOf,IInformationFlow,IInputPin,IInstanceSpecification,IInteraction,IInteractionFragment,IInteractionOperand,IInteractionUse,IInterfaceBlock,IInternalBlockDiagram,IItemFlow,IJustification,ILifeline,ILifelineLink,ILink,ILink,ILinkableElement,ILinkEnd,ILinkEnd,ILossScenarioTable,IMessage,IMindMapDiagram,IModel,IModule,INamedElement,INode,IObjectNode,IOperation,IOutputPin,IPackage,IParameter,IParametricDiagram,IPartition,IPin,IPort,IPrecondition,IPreconditionTable,IPrimitiveType,IProcessModel,IProcessValue,IProcessVariable,IPseudostate,IQuantityKind,IRealization,IRelationship,IRequirement,IRequirementDiagram,IRequirementTable,ISafetyConstraint,ISequenceDiagram,ISignal,ISlot,ISolution,IStampComment,IStampDiagram,IStampElement,IState,IStateInvariant,IStateMachine,IStateMachineDiagram,IStpaAnalysis,IStrategy,ISubsystem,ISupportedBy,ITaggedValue,ITemplateBinding,ITermination,ITestCase,ITimeConstraint,ITransition,IUCATable,IUnit,IUnsafeControlAction,IUsage,IUseCase,IUseCaseDiagram,IValueAttribute,IValueProperty,IValueType,IValueTypeProperty,IVertex
Interface for elements.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddStereotype(String stereotype) Add a stereotype.IComment[]Get Comments.Get hierarchy parent including namespace.IElement[]Get hierarchy parents including namespace.getId()Get ID.getOwner()Get Namespace.Get Presentations.String[]Get Stereotypes.getTaggedValue(String key) Get The Value Of Specified Tagged Values.Get Tagged Values.Get Type Modifier.booleanhasStereotype(String stereotype) True if the element has the target Stereotype.booleanCheck if this element is read only.voidremoveStereotype(String stereotype) Remove a stereotype.voidsetTypeModifier(String typeModifier) Not implemented yet. Set Type Modifier.
-
Method Details
-
getId
String getId()Get ID.- Returns:
- ID.
-
getOwner
IElement getOwner()Get Namespace.- Returns:
- Namespace. Return null in case there is none.
-
getContainer
IElement getContainer()Get hierarchy parent including namespace. If State2 is in State1 on a diagram, state1 is the parent of state2.- Returns:
- Hierarchy parent. Return null in case there is none.
-
getContainers
IElement[] getContainers()Get hierarchy parents including namespace. Vertical partition and horizontal partition can be got at the same time.- Returns:
- Hierarchy parent. Return the empty array if there is none.
-
getComments
IComment[] getComments()Get Comments.- Returns:
- The array of Comments. Return the empty array if there is none.
-
getStereotypes
String[] getStereotypes()Get Stereotypes.- Returns:
- The array of stereotypes. Return the empty array if there is none.
-
hasStereotype
True if the element has the target Stereotype.- Parameters:
stereotype- Stereotype- Returns:
- true if the element has the target Stereotype.
- Since:
- 6.6.4
-
removeStereotype
Remove a stereotype.- Parameters:
stereotype- Stereotype- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in astah* community. PARAMETER_ERROR_KEY - if a parameter is not set properly. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred. READ_ONLY_KEY - if a read-only element is edited.Values: Error messages for exceptions.
-
addStereotype
Add a stereotype.- Parameters:
stereotype- Stereotype- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in astah* community. PARAMETER_ERROR_KEY - if a parameter is not set properly. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred. READ_ONLY_KEY - if a read-only element is edited.Values: Error messages for exceptions.
-
getTaggedValues
ITaggedValue[] getTaggedValues()Get Tagged Values.- Returns:
- the array of Tagged Values. Return the empty array if there is none.
-
getTaggedValue
Get The Value Of Specified Tagged Values.- Returns:
- The value of Specified tagged value. Return "" if there is none.
-
isReadOnly
boolean isReadOnly()Check if this element is read only.- Returns:
- true the element is read only / false the element is not read only
-
getTypeModifier
String getTypeModifier()Get Type Modifier.- Returns:
- Type Modifier.
-
getPresentations
IPresentation[] getPresentations()Get Presentations.- Returns:
- the array of presentations. Return the empty array if there is none.
- Throws:
InvalidUsingException- InvalidUsingException occurs.Keys: ILLEGAL_USE_ERROR_KEY - if Presentation API is used in astah* community.Values: Error messages for exceptions.
-
setTypeModifier
Not implemented yet. Set Type Modifier.- Parameters:
typeModifier- Type Modifier- Throws:
InvalidEditingException- InvalidEditingException occurs.Keys: ILLEGAL_VERSION_ERROR_KEY - if Editing API is used in astah* community. INVALID_TYPE_MODIFIER_MODEL_ERROR_KEY - if a Type Modifier cannot be set to the model. BAD_TRANSACTION_KEY - Bad Transaction. HAS_EXCEPTION_KEY - if an exception has occurred. READ_ONLY_KEY - if a read-only element is edited.Values: Error messages for exceptions.
-