public class AllInstancesNavigationStep extends AbstractNavigationStep
| Constructor and Description |
|---|
AllInstancesNavigationStep(org.eclipse.emf.ecore.EClass sourceType,
org.eclipse.emf.ecore.EClass targetType,
OCLExpression debugInfo,
OppositeEndFinder oppositeEndFinder)
Constructs a non-
absolute navigation step that computes all instances of
targetType and all its direct and indirect subtypes, if the fromObject passed to
AbstractNavigationStep.navigate(Set, TracebackCache, Notification) conforms to the sourceType. |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
contentToString(java.util.Map<NavigationStep,java.lang.Integer> visited,
int indent) |
boolean |
isAbsolute()
Always returns
false. |
protected java.util.Set<AnnotatedEObject> |
navigate(AnnotatedEObject fromObject,
TracebackCache cache,
org.eclipse.emf.common.notify.Notification changeEvent) |
addAlwaysEmptyChangeListener, addEnteringScopes, addExpressionForWhichThisIsNavigationStep, addHashCodeChangeListener, addLeavingScopes, addSourceTypeChangeListener, addTargetTypeChangeListener, annotateEObject, distinctSize, distinctSize, doesSourceTypeMatch, fireAfterHashCodeChange, fireBeforeHashCodeChange, getDebugInfo, getEnteringScopes, getId, getLeavingScopes, getNavigateCounter, getResultObjectsCounter, getSemanticIdentity, getSourceType, getTargetType, haveIntersectingSubclassTree, incrementNavigateCounter, isAlwaysEmpty, navigate, newTokenForFiringHashCodeChangeEvent, setAlwaysEmpty, size, size, toString, toStringpublic AllInstancesNavigationStep(org.eclipse.emf.ecore.EClass sourceType,
org.eclipse.emf.ecore.EClass targetType,
OCLExpression debugInfo,
OppositeEndFinder oppositeEndFinder)
absolute navigation step that computes all instances of
targetType and all its direct and indirect subtypes, if the fromObject passed to
AbstractNavigationStep.navigate(Set, TracebackCache, Notification) conforms to the sourceType. Otherwise, an empty set is returned. The consideration of
the fromObject is the reason why if constructed with this constructor an object of this class is not absolute.debugInfo - oppositeEndFinder - used during partial evaluation and for metamodel queries, e.g., finding opposite role names, or finding all
subclasses of a class; as well as for obtaining all instances of a type while performing an
AllInstancesNavigationStep. It is handed to the PathCache object from where Tracers can
retrieve it using AbstractPathCache.getOppositeEndFinder().protected java.util.Set<AnnotatedEObject> navigate(AnnotatedEObject fromObject, TracebackCache cache, org.eclipse.emf.common.notify.Notification changeEvent)
navigate in class AbstractNavigationSteppublic java.lang.String contentToString(java.util.Map<NavigationStep,java.lang.Integer> visited, int indent)
contentToString in class AbstractNavigationSteppublic boolean isAbsolute()
false. See
AllInstancesNavigationStep(EClass, EClass, OCLExpression, OppositeEndFinder)isAbsolute in interface NavigationStepisAbsolute in class AbstractNavigationStep