Class AssignmentActions
java.lang.Object
com.dassault_systemes.modeler.sysml.model.AssignmentActions
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intIndex of the replacement-values input parameter.static final intIndex of the target input parameter. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidcreateTargetParameterStartingAt(Feature targetParameter) Initializes a newly created target parameter with a nested reference structure:static FeatureReturns the replacement-values parameter of the assignment action, creating it if necessary.static FeaturegetOrCreateTargetParameter(AssignmentActionUsage actionUsage) Returns the target parameter of the assignment action, creating it if necessary.static FeaturegetOwnedReplacementValuesParameter(AssignmentActionUsage actionUsage) Returns the owned replacement-values parameter of the assignment action, ornullif it has not been created.static FeaturegetOwnedTargetParameter(AssignmentActionUsage actionUsage) Returns the owned target parameter of the assignment action, ornullif it has not been created.static MembershipgetReferentMembership(AssignmentActionUsage actionUsage) Returns the referent membership of the assignment action, excluding feature memberships.static voidsetReferent(AssignmentActionUsage actionUsage, Feature referent) Sets the referent of the assignment action.
-
Field Details
-
TARGET_PARAMETER_INDEX
public static final int TARGET_PARAMETER_INDEXIndex of the target input parameter.- See Also:
-
REPLACEMENT_VALUES_PARAMETER_INDEX
public static final int REPLACEMENT_VALUES_PARAMETER_INDEXIndex of the replacement-values input parameter.- See Also:
-
-
Constructor Details
-
AssignmentActions
public AssignmentActions()
-
-
Method Details
-
getOwnedTargetParameter
Returns the owned target parameter of the assignment action, ornullif it has not been created.- Parameters:
actionUsage- the assignment action usage- Returns:
- the owned target parameter, or
null
-
getOrCreateTargetParameter
Returns the target parameter of the assignment action, creating it if necessary. When created, the parameter is initialized with a nested reference structure representing the “startingAt → accessedFeature” pattern.- Parameters:
actionUsage- the assignment action usage- Returns:
- the existing or newly created target parameter
-
createTargetParameterStartingAt
Initializes a newly created target parameter with a nested reference structure:targetParameter └─ startingAt : ReferenceUsage └─ accessedFeature : ReferenceUsageThis mirrors the typical structure of assignment target expressions.- Parameters:
targetParameter- the target parameter to initialize
-
getOwnedReplacementValuesParameter
@CheckForNull public static Feature getOwnedReplacementValuesParameter(AssignmentActionUsage actionUsage) Returns the owned replacement-values parameter of the assignment action, ornullif it has not been created.- Parameters:
actionUsage- the assignment action usage- Returns:
- the owned replacement-values parameter, or
null
-
getOrCreateReplacementValuesParameter
Returns the replacement-values parameter of the assignment action, creating it if necessary.- Parameters:
actionUsage- the assignment action usage- Returns:
- the existing or newly created replacement-values parameter
-
setReferent
Sets the referent of the assignment action. The referent membership is inserted immediately after the target parameter.- Parameters:
actionUsage- the assignment action usagereferent- the feature to set as the referent
-
getReferentMembership
Returns the referent membership of the assignment action, excluding feature memberships. This identifies the membership that holds the referent feature for the assignment.- Parameters:
actionUsage- the assignment action usage- Returns:
- the referent membership, or
null
-