|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.xtext.scoping.impl.AbstractScope org.eclipse.ocl.examples.xtext.base.scoping.BaseScopeView
public class BaseScopeView
ScopeViews support access to some or all of the elements in a scope. Accesses are filtered on the fly since a cache of results does not remain valid for long enough to merit it, with incremental reparsing regularly trashing the CST.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.eclipse.xtext.scoping.impl.AbstractScope |
---|
org.eclipse.xtext.scoping.impl.AbstractScope.ParentIterable |
Field Summary | |
---|---|
protected ElementCS |
child
|
protected boolean |
isQualified
|
protected MetaModelManager |
metaModelManager
|
static IScopeView |
NULLSCOPEVIEW
The NULLSCOPEVIEW to be returned by the most outer scope |
protected ElementCS |
target
|
protected org.eclipse.emf.ecore.EReference |
targetReference
|
Fields inherited from interface org.eclipse.xtext.scoping.IScope |
---|
NULLSCOPE |
Constructor Summary | |
---|---|
protected |
BaseScopeView(MetaModelManager metaModelManager,
ElementCS target,
ElementCS child,
org.eclipse.emf.ecore.EReference targetReference,
boolean isQualified)
|
Method Summary | |
---|---|
java.lang.Iterable<org.eclipse.xtext.resource.IEObjectDescription> |
getAllElements()
|
protected java.lang.Iterable<org.eclipse.xtext.resource.IEObjectDescription> |
getAllLocalElements()
|
Attribution |
getAttribution()
Return Attribution instance that defines the lookup algorithm for the target node. |
ElementCS |
getChild()
Return the immediate child node for which a lookup is requested. |
org.eclipse.emf.ecore.EStructuralFeature |
getContainmentFeature()
Return the containment feature of the child within the target. |
java.lang.Iterable<org.eclipse.xtext.resource.IEObjectDescription> |
getElements(org.eclipse.emf.ecore.EObject object)
|
java.lang.Iterable<org.eclipse.xtext.resource.IEObjectDescription> |
getElements(org.eclipse.xtext.naming.QualifiedName name)
|
MetaModelManager |
getMetaModelManager()
|
IScopeView |
getParent()
Return the ScopeView that characterizes a lookup in the parent of the target node. |
IScopeView |
getRoot()
Return the ScopeView that characterizes a lookup at the top level. |
static BaseScopeView |
getScopeView(MetaModelManager metaModelManager,
ElementCS target,
org.eclipse.emf.ecore.EReference targetReference)
|
org.eclipse.xtext.resource.IEObjectDescription |
getSingleElement(org.eclipse.emf.ecore.EObject object)
|
org.eclipse.xtext.resource.IEObjectDescription |
getSingleElement(org.eclipse.xtext.naming.QualifiedName name)
|
ElementCS |
getTarget()
Return the target node at which this ScopeView characterizes a lookup. |
boolean |
isQualified()
Return true if the lookup is within a qualified name. |
java.lang.String |
toString()
|
Methods inherited from class org.eclipse.xtext.scoping.impl.AbstractScope |
---|
getLocalElementsByEObject, getLocalElementsByName, getParentElements, getSingleLocalElementByName, isIgnoreCase, isShadowed |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
@NonNull public static final IScopeView NULLSCOPEVIEW
NULLSCOPEVIEW
to be returned by the most outer scope
@NonNull protected final MetaModelManager metaModelManager
@NonNull protected final ElementCS target
@Nullable protected final ElementCS child
@NonNull protected final org.eclipse.emf.ecore.EReference targetReference
protected final boolean isQualified
Constructor Detail |
---|
protected BaseScopeView(@NonNull MetaModelManager metaModelManager, @NonNull ElementCS target, @Nullable ElementCS child, @NonNull org.eclipse.emf.ecore.EReference targetReference, boolean isQualified)
Method Detail |
---|
@NonNull public static BaseScopeView getScopeView(@NonNull MetaModelManager metaModelManager, @NonNull ElementCS target, @NonNull org.eclipse.emf.ecore.EReference targetReference)
@NonNull public Attribution getAttribution()
ScopeView
getAttribution
in interface ScopeView
public java.lang.Iterable<org.eclipse.xtext.resource.IEObjectDescription> getAllElements()
getAllElements
in interface org.eclipse.xtext.scoping.IScope
getAllElements
in class org.eclipse.xtext.scoping.impl.AbstractScope
protected final java.lang.Iterable<org.eclipse.xtext.resource.IEObjectDescription> getAllLocalElements()
getAllLocalElements
in class org.eclipse.xtext.scoping.impl.AbstractScope
@Nullable public ElementCS getChild()
ScopeView
getChild
in interface ScopeView
public org.eclipse.emf.ecore.EStructuralFeature getContainmentFeature()
ScopeView
getContainmentFeature
in interface ScopeView
public java.lang.Iterable<org.eclipse.xtext.resource.IEObjectDescription> getElements(org.eclipse.xtext.naming.QualifiedName name)
getElements
in interface org.eclipse.xtext.scoping.IScope
getElements
in class org.eclipse.xtext.scoping.impl.AbstractScope
public java.lang.Iterable<org.eclipse.xtext.resource.IEObjectDescription> getElements(org.eclipse.emf.ecore.EObject object)
getElements
in interface org.eclipse.xtext.scoping.IScope
getElements
in class org.eclipse.xtext.scoping.impl.AbstractScope
public MetaModelManager getMetaModelManager()
@NonNull public IScopeView getParent()
ScopeView
getParent
in interface ScopeView
getParent
in interface IScopeView
getParent
in class org.eclipse.xtext.scoping.impl.AbstractScope
@NonNull public IScopeView getRoot()
ScopeView
getRoot
in interface ScopeView
getRoot
in interface IScopeView
public org.eclipse.xtext.resource.IEObjectDescription getSingleElement(org.eclipse.emf.ecore.EObject object)
getSingleElement
in interface org.eclipse.xtext.scoping.IScope
getSingleElement
in class org.eclipse.xtext.scoping.impl.AbstractScope
@Nullable public org.eclipse.xtext.resource.IEObjectDescription getSingleElement(org.eclipse.xtext.naming.QualifiedName name)
getSingleElement
in interface org.eclipse.xtext.scoping.IScope
getSingleElement
in class org.eclipse.xtext.scoping.impl.AbstractScope
@NonNull public final ElementCS getTarget()
ScopeView
getTarget
in interface ScopeView
public final boolean isQualified()
ScopeView
isQualified
in interface ScopeView
public java.lang.String toString()
toString
in class org.eclipse.xtext.scoping.impl.AbstractScope
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |