Package com.iizigo.vs.link
Class VSLinkAction
- java.lang.Object
-
- com.iizigo.vs.link.VSLinkInfo<EditorVSAction>
-
- com.iizigo.vs.link.VSLinkAction
-
public class VSLinkAction extends VSLinkInfo<EditorVSAction>
Links a VSAction to a target component, or replaces an existing one.- Author:
- Christopher Mindus
-
-
Constructor Summary
Constructors Constructor Description VSLinkAction(Atom atom)
The constructor takes the VSActionReference atom for the operation.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.String
getOperation(PropCnr target, EditorVSAction component)
Returns the operation that linking will produce.java.lang.Class<EditorVSAction>
getVSClass()
Returns the class used for linking.protected boolean
isAlreadyLinked(PropCnr target, EditorVSAction component)
Verifies if the component has been linked already.protected boolean
isMultipleComponentsSupported()
Returns if the linker implementation supports multiple components or a single one.protected PropCnr
runOperation(PropCnr target, java.util.ArrayList<EditorVSAction> components, VSSubLinkInfo subOperations, PropCnr mainContainer, ComplexOperation op)
Runs the main operation.-
Methods inherited from class com.iizigo.vs.link.VSLinkInfo
getAlreadyLinkedMessage, getNoComponentsMessage, getSubOperations, isSkipDialogAllowed
-
-
-
-
Constructor Detail
-
VSLinkAction
public VSLinkAction(Atom atom)
The constructor takes the VSActionReference atom for the operation.- Parameters:
atom
- The atom for the reference property.
-
-
Method Detail
-
getVSClass
public java.lang.Class<EditorVSAction> getVSClass()
Returns the class used for linking.- Specified by:
getVSClass
in classVSLinkInfo<EditorVSAction>
- Returns:
- EditorVSAction.class.
-
isAlreadyLinked
protected boolean isAlreadyLinked(PropCnr target, EditorVSAction component)
Verifies if the component has been linked already.- Specified by:
isAlreadyLinked
in classVSLinkInfo<EditorVSAction>
- Parameters:
target
- The target for linking.component
- The component.- Returns:
- true if already handled by this link info.
-
getOperation
protected java.lang.String getOperation(PropCnr target, EditorVSAction component)
Returns the operation that linking will produce.- Specified by:
getOperation
in classVSLinkInfo<EditorVSAction>
- Parameters:
target
- The target for linking.component
- The component to link.- Returns:
- The text inserted to the table.
-
isMultipleComponentsSupported
protected boolean isMultipleComponentsSupported()
Returns if the linker implementation supports multiple components or a single one.- Specified by:
isMultipleComponentsSupported
in classVSLinkInfo<EditorVSAction>
- Returns:
- true if multiple components can be handled, or false for a single one
in the list of components for the
operation.runOperation(PropCnr, ArrayList, VSSubLinkInfo, PropCnr, ComplexOperation)
-
runOperation
protected PropCnr runOperation(PropCnr target, java.util.ArrayList<EditorVSAction> components, VSSubLinkInfo subOperations, PropCnr mainContainer, ComplexOperation op)
Runs the main operation.- Specified by:
runOperation
in classVSLinkInfo<EditorVSAction>
- Parameters:
target
- The target for linking.components
- The components to link (just one due to "isMultipleComponentsSupported()==false").subOperations
- Sub-operations to execute, null for none.mainContainer
- The main container from a parent operation, null for main operation.op
- The complex operation.- Returns:
- Potential property container created, for use in sub-operations.
-
-