org.eclipse.gmt.umlx.editor.regime
Class AbstractLinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

java.lang.Object
  extended by org.eclipse.gmt.umlx.utils.ClassExtension<M>
      extended by org.eclipse.gmt.umlx.editor.regime.AbstractRegime<LM,P>
          extended by org.eclipse.gmt.umlx.editor.regime.AbstractLinkRegimeCo0<SM,LM,TM,P>
All Implemented Interfaces:
ILinkRegimeCo0<SM,LM,TM,P>, ILinkRegimeEnums, IRegime, IRegimeCo0<LM,P>, IClassExtension
Direct Known Subclasses:
AbstractAutoELinkRegime, AbstractLinkRegimeCo1, AbstractTransientLinkCo0Regime, E2AssociationRegime, E2DirectedAssociationRegime, EReferenceRegime, GSheetLinkRegimeCo0, UAttributeVariable2UExpressionVariableRegime, UBindingRegime

public abstract class AbstractLinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
extends AbstractRegime<LM,P>
implements ILinkRegimeCo0<SM,LM,TM,P>


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.eclipse.gmt.umlx.editor.regime.ILinkRegimeEnums
ILinkRegimeEnums.IsCreate, ILinkRegimeEnums.IsReconnect, ILinkRegimeEnums.IsReCreate
 
Method Summary
 void addConnection(int sourceIndex, ILinkEnd sourceEnd, LM link, ILinkEnd targetEnd, int targetIndex)
           
 boolean canBeReversed()
          Return true if the link may be drawn backwards.
 IErrorMessage cannotConnectBetween(java.lang.Object source, java.lang.Object target, ILinkRegimeEnums.IsReCreate isReCreate, CandidateLinks candidates)
          Return a reason why a connection cannot be made from source to target, or null if it can, and add the possible instantiations to candidates.
 IErrorMessage cannotConnectFrom(java.lang.Object source, ILinkRegimeEnums.IsCreate isCreate)
          Return a reason why a connection cannot start from source or null if it can.
 IErrorMessage cannotConnectTo(java.lang.Object target, ILinkRegimeEnums.IsCreate isCreate)
          Return a reason why a connection cannot finish at target or null if it can.
 IModelStateCommand createCreateCommand(IActiveEditDomain editDomain, java.lang.Object coModel, java.lang.Object context, ILinkEnd sourceLinkEnd, ILinkEnd targetLinkEnd)
           
 void createFacets(java.util.List<IFacet<? super LM>> facetList)
           
 LinkFigure createFigure(ILinkViewElement view)
          Create the figure object to be drawn in the sheet editor.
 ILinkEnd createLinkEnd(java.lang.Object object)
          Create an object to describe the end of a link terminating at object.
 LM createModelObject(ILinkEnd sourceLinkEnd, ILinkEnd targetLinkEnd)
           
 ReconnectCommand createReconnectCommand(java.lang.Object newSource, java.lang.Object link, java.lang.Object newTarget)
           
 LM getActualConnection(SM source, TM target)
          Return a connection between source and target if present in the model.
 IErrorMessage getActualConnectionsBetween(ILinkEnd sourceLinkEnd, ILinkEnd targetLinkEnd, CandidateLinks candidates)
          Compute a list of the connections that currently exist between source and target or return an error message if connections are not possible.
 java.util.List<org.eclipse.draw2d.Bendpoint> getBendpoints(java.lang.Object model)
           
 java.util.List<?> getCoCoModelsFor(java.lang.Object coSource, java.lang.Object coTarget)
           
 ILinkRegimeCo0<?,?,?,?> getCoRegime()
          Return the co-regime if it has one.
 LM getPotentialCoConnection(SM source, TM target)
          Return the co-model of a connection between source and target that could be present in the model.
 void getPotentialCoConnectionsBetween(java.lang.Object source, java.lang.Object target, CandidateLinks candidates)
           
 LM getPotentialConnection(SM source, TM target)
          Return the connection between source and target that could be present in the model.
 void getPotentialConnectionsBetween(ILinkEnd sourceLinkEnd, ILinkEnd targetLinkEnd, CandidateLinks candidates)
          Compute a list of the co-models of the connections between source and target that are or could be present in the model.
 SM getSource(java.lang.Object model)
          Return the source node of model if it is a link.
abstract  SM getSource0(LM model)
           
 java.util.List<? super LM> getSourceConnections(java.lang.Object source)
           
 ILinkEnd getSourceLinkEnd(java.lang.Object model)
           
 java.lang.Class<SM> getSourceModelClass()
          Return the class of source nodes if appropriate
 org.eclipse.emf.ecore.EObject getSourceNode(java.lang.Object model)
          Return the node at the source of this link.
 TM getTarget(java.lang.Object model)
          Return the target node of model if it is a link.
abstract  TM getTarget0(LM model)
           
 java.util.List<? super LM> getTargetConnections(java.lang.Object target)
           
 ILinkEnd getTargetLinkEnd(java.lang.Object model)
           
 java.lang.Class<TM> getTargetModelClass()
          Return the class of target nodes if appropriate
 org.eclipse.emf.ecore.EObject getTargetNode(java.lang.Object model)
          Return the node at the target of this link.
 boolean isContainment()
          Return true if this is a containment of the target by the source.
 ILinkRegimeCo0<?,LM,?,P> isLink()
           
 ILinkRegimeCo1<SM,LM,TM,P,?,?> isRegimeCo1()
          Return this non-null regime if it is suitable for use with one or more levels of co-model.
 ILinkRegimeCo2<SM,LM,TM,P,?,?> isRegimeCo2()
          Return this non-null regime if it is suitable for use with two or more levels of co-model.
 java.lang.Integer[] removeConnection(SM source, LM link, TM target)
           
 ILinkRegimeCo0<?,?,?,?> resolveRegime(java.lang.Object source, java.lang.Object target)
          Return a regime appropriate to source and target.
 boolean sourceIsOptional()
          Return true if source need not be present in a valid model.
 boolean targetIsOptional()
          Return true if target need not be present in a valid model.
 
Methods inherited from class org.eclipse.gmt.umlx.editor.regime.AbstractRegime
canCopy, canDelete, computeProblemMessage, createCreateChildLinkCommand, createCreateCommand, createDeleteCommand, createModelObject, createOutline, createPropertySource, createView, getBackElement, getBasicClass, getCoModel, getCoModelClass, getCoModelParentClass, getFacets, getModelClass, getNewNamePrefix, getParentModelClass, getSheetClass, initialise, isNode, isRegimeCo0, load, refreshProblemMessage, setCoModel, toString
 
Methods inherited from class org.eclipse.gmt.umlx.utils.ClassExtension
toDebugString, toUserString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.eclipse.gmt.umlx.editor.regime.IRegimeCo0
canCopy, canDelete, computeProblemMessage, createDeleteCommand, createModelObject, createOutline, createPropertySource, createView, getFacets, getModelClass, getParentModelClass, isNode, isRegimeCo0, refreshProblemMessage, setCoModel
 
Methods inherited from interface org.eclipse.gmt.umlx.editor.regime.IRegime
createCreateChildLinkCommand, createCreateCommand, getBackElement, getCoModel, getCoModelClass, getCoModelParentClass, getIcon, getLabel, getNewNamePrefix, getSheetClass
 
Methods inherited from interface org.eclipse.gmt.umlx.utils.IClassExtension
getBasicClass, toDebugString, toUserString
 

Method Detail

addConnection

public void addConnection(int sourceIndex,
                          ILinkEnd sourceEnd,
                          LM link,
                          ILinkEnd targetEnd,
                          int targetIndex)
Specified by:
addConnection in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

canBeReversed

public boolean canBeReversed()
Description copied from interface: ILinkRegimeCo0
Return true if the link may be drawn backwards.

Specified by:
canBeReversed in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Returns:
true if reversable

cannotConnectBetween

public IErrorMessage cannotConnectBetween(java.lang.Object source,
                                          java.lang.Object target,
                                          ILinkRegimeEnums.IsReCreate isReCreate,
                                          CandidateLinks candidates)
Description copied from interface: ILinkRegimeCo0
Return a reason why a connection cannot be made from source to target, or null if it can, and add the possible instantiations to candidates.

Specified by:
cannotConnectBetween in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
source - source of required connection
target - target of required connection
candidates - list to receive candidate connections
Returns:
non-null reason for connection failure

cannotConnectFrom

public IErrorMessage cannotConnectFrom(java.lang.Object source,
                                       ILinkRegimeEnums.IsCreate isCreate)
Description copied from interface: ILinkRegimeCo0
Return a reason why a connection cannot start from source or null if it can.

Specified by:
cannotConnectFrom in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
source - source of required connection
isCreate - true if check for creation rather than use
Returns:
non-null reason for connection failure

cannotConnectTo

public IErrorMessage cannotConnectTo(java.lang.Object target,
                                     ILinkRegimeEnums.IsCreate isCreate)
Description copied from interface: ILinkRegimeCo0
Return a reason why a connection cannot finish at target or null if it can.

Specified by:
cannotConnectTo in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
target - target of required connection
isCreate - true if check for creation rather than use
Returns:
non-null reason for connection failure

createCreateCommand

public IModelStateCommand createCreateCommand(IActiveEditDomain editDomain,
                                              java.lang.Object coModel,
                                              java.lang.Object context,
                                              ILinkEnd sourceLinkEnd,
                                              ILinkEnd targetLinkEnd)
Specified by:
createCreateCommand in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

createFacets

public void createFacets(java.util.List<IFacet<? super LM>> facetList)
Overrides:
createFacets in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>

createFigure

public LinkFigure createFigure(ILinkViewElement view)
Description copied from interface: ILinkRegimeCo0
Create the figure object to be drawn in the sheet editor.

Specified by:
createFigure in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Returns:
a figure

createLinkEnd

public ILinkEnd createLinkEnd(java.lang.Object object)
Description copied from interface: IRegime
Create an object to describe the end of a link terminating at object.

Specified by:
createLinkEnd in interface IRegime
Overrides:
createLinkEnd in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>

createModelObject

public LM createModelObject(ILinkEnd sourceLinkEnd,
                            ILinkEnd targetLinkEnd)
Specified by:
createModelObject in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

createReconnectCommand

public ReconnectCommand createReconnectCommand(java.lang.Object newSource,
                                               java.lang.Object link,
                                               java.lang.Object newTarget)
Specified by:
createReconnectCommand in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getActualConnection

public final LM getActualConnection(SM source,
                                    TM target)
Description copied from interface: ILinkRegimeCo0
Return a connection between source and target if present in the model. Any required transient link is created. In the case of duplicates an arbitrary choice is made.

Specified by:
getActualConnection in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
source - source of required connection
target - target of required connection
Returns:
the connection or null.

getActualConnectionsBetween

public IErrorMessage getActualConnectionsBetween(ILinkEnd sourceLinkEnd,
                                                 ILinkEnd targetLinkEnd,
                                                 CandidateLinks candidates)
Description copied from interface: ILinkRegimeCo0
Compute a list of the connections that currently exist between source and target or return an error message if connections are not possible.

Specified by:
getActualConnectionsBetween in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
sourceLinkEnd - source of required connection
targetLinkEnd - target of required connection
candidates - list to which current connections are added
Returns:
a non-null error message if arguments illegal.

getBendpoints

public java.util.List<org.eclipse.draw2d.Bendpoint> getBendpoints(java.lang.Object model)
Specified by:
getBendpoints in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getCoCoModelsFor

public java.util.List<?> getCoCoModelsFor(java.lang.Object coSource,
                                          java.lang.Object coTarget)
Specified by:
getCoCoModelsFor in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getCoRegime

public ILinkRegimeCo0<?,?,?,?> getCoRegime()
Description copied from interface: IRegime
Return the co-regime if it has one.

Specified by:
getCoRegime in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Specified by:
getCoRegime in interface IRegime
Specified by:
getCoRegime in interface IRegimeCo0<LM extends org.eclipse.emf.ecore.EModelElement,P>
Specified by:
getCoRegime in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>
Returns:
co-regime class or null

getPotentialCoConnection

public final LM getPotentialCoConnection(SM source,
                                         TM target)
Description copied from interface: ILinkRegimeCo0
Return the co-model of a connection between source and target that could be present in the model. Any required transient link is created. In the case of duplicates an arbitrary choice is made.

Specified by:
getPotentialCoConnection in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
source - source of required connection
target - target of required connection
Returns:
the connection or null.

getPotentialCoConnectionsBetween

public final void getPotentialCoConnectionsBetween(java.lang.Object source,
                                                   java.lang.Object target,
                                                   CandidateLinks candidates)

getPotentialConnection

public LM getPotentialConnection(SM source,
                                 TM target)
Description copied from interface: ILinkRegimeCo0
Return the connection between source and target that could be present in the model. Any required transient link is created. In the case of duplicates an arbitrary choice is made.

Specified by:
getPotentialConnection in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
source - source of required connection
target - target of required connection
Returns:
the connection or null.

getPotentialConnectionsBetween

public void getPotentialConnectionsBetween(ILinkEnd sourceLinkEnd,
                                           ILinkEnd targetLinkEnd,
                                           CandidateLinks candidates)
Description copied from interface: ILinkRegimeCo0
Compute a list of the co-models of the connections between source and target that are or could be present in the model. If connections already exist they alone are returned. Potential connections are only returned when no current connections exist.

Specified by:
getPotentialConnectionsBetween in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
sourceLinkEnd - source of required connection
targetLinkEnd - target of required connection
candidates - list to which current and possible connections are added

getSource

public final SM getSource(java.lang.Object model)
Description copied from interface: IRegime
Return the source node of model if it is a link.

Specified by:
getSource in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Specified by:
getSource in interface IRegime
Overrides:
getSource in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>
Parameters:
model - model
Returns:
this or null

getSource0

public abstract SM getSource0(LM model)
Specified by:
getSource0 in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getSourceConnections

public java.util.List<? super LM> getSourceConnections(java.lang.Object source)
Specified by:
getSourceConnections in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getSourceLinkEnd

public ILinkEnd getSourceLinkEnd(java.lang.Object model)
Specified by:
getSourceLinkEnd in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getSourceModelClass

public java.lang.Class<SM> getSourceModelClass()
Description copied from interface: IRegime
Return the class of source nodes if appropriate

Specified by:
getSourceModelClass in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Specified by:
getSourceModelClass in interface IRegime
Overrides:
getSourceModelClass in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>
Returns:
source node class or null

getSourceNode

public org.eclipse.emf.ecore.EObject getSourceNode(java.lang.Object model)
Description copied from interface: ILinkRegimeCo0
Return the node at the source of this link. This is normally the same as getSource() except for links of links such as E2Association for which this traverses to the node ratryher than the property.

Specified by:
getSourceNode in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
model - to traverse
Returns:
the source node

getTarget

public final TM getTarget(java.lang.Object model)
Description copied from interface: IRegime
Return the target node of model if it is a link.

Specified by:
getTarget in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Specified by:
getTarget in interface IRegime
Overrides:
getTarget in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>
Parameters:
model - model
Returns:
this or null

getTarget0

public abstract TM getTarget0(LM model)
Specified by:
getTarget0 in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getTargetConnections

public java.util.List<? super LM> getTargetConnections(java.lang.Object target)
Specified by:
getTargetConnections in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getTargetLinkEnd

public ILinkEnd getTargetLinkEnd(java.lang.Object model)
Specified by:
getTargetLinkEnd in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

getTargetModelClass

public java.lang.Class<TM> getTargetModelClass()
Description copied from interface: IRegime
Return the class of target nodes if appropriate

Specified by:
getTargetModelClass in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Specified by:
getTargetModelClass in interface IRegime
Overrides:
getTargetModelClass in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>
Returns:
target node class or null

getTargetNode

public org.eclipse.emf.ecore.EObject getTargetNode(java.lang.Object model)
Description copied from interface: ILinkRegimeCo0
Return the node at the target of this link. This is normally the same as getTarget() except for links of links such as E2Association for which this traverses to the node ratryher than the property.

Specified by:
getTargetNode in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Parameters:
model - to traverse
Returns:
the target node

isContainment

public boolean isContainment()
Return true if this is a containment of the target by the source.

Specified by:
isContainment in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Returns:
if a containment relationship.

isLink

public ILinkRegimeCo0<?,LM,?,P> isLink()
Specified by:
isLink in interface IRegimeCo0<LM extends org.eclipse.emf.ecore.EModelElement,P>
Overrides:
isLink in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>

isRegimeCo1

public ILinkRegimeCo1<SM,LM,TM,P,?,?> isRegimeCo1()
Description copied from interface: IRegime
Return this non-null regime if it is suitable for use with one or more levels of co-model.

Specified by:
isRegimeCo1 in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Specified by:
isRegimeCo1 in interface IRegime
Specified by:
isRegimeCo1 in interface IRegimeCo0<LM extends org.eclipse.emf.ecore.EModelElement,P>
Overrides:
isRegimeCo1 in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>
Returns:
this or null

isRegimeCo2

public ILinkRegimeCo2<SM,LM,TM,P,?,?> isRegimeCo2()
Description copied from interface: IRegime
Return this non-null regime if it is suitable for use with two or more levels of co-model.

Specified by:
isRegimeCo2 in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Specified by:
isRegimeCo2 in interface IRegime
Specified by:
isRegimeCo2 in interface IRegimeCo0<LM extends org.eclipse.emf.ecore.EModelElement,P>
Overrides:
isRegimeCo2 in class AbstractRegime<LM extends org.eclipse.emf.ecore.EModelElement,P>
Returns:
this or null

removeConnection

public java.lang.Integer[] removeConnection(SM source,
                                            LM link,
                                            TM target)
Specified by:
removeConnection in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

resolveRegime

public ILinkRegimeCo0<?,?,?,?> resolveRegime(java.lang.Object source,
                                             java.lang.Object target)
Description copied from interface: ILinkRegimeCo0
Return a regime appropriate to source and target. This allows a generic smart regime to be invoked initially that redirects in a context-specific fashion.

Specified by:
resolveRegime in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>

sourceIsOptional

public boolean sourceIsOptional()
Description copied from interface: ILinkRegimeCo0
Return true if source need not be present in a valid model.

Specified by:
sourceIsOptional in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Returns:
true if source need not be present in a valid model.

targetIsOptional

public boolean targetIsOptional()
Description copied from interface: ILinkRegimeCo0
Return true if target need not be present in a valid model.

Specified by:
targetIsOptional in interface ILinkRegimeCo0<SM extends org.eclipse.emf.ecore.EObject,LM extends org.eclipse.emf.ecore.EModelElement,TM extends org.eclipse.emf.ecore.EObject,P>
Returns:
true if target need not be present in a valid model.