org.eclipse.xtext.scoping.impl
Class AbstractGlobalScopeProvider
java.lang.Object
org.eclipse.xtext.scoping.impl.AbstractGlobalScopeProvider
- All Implemented Interfaces:
- IGlobalScopeProvider
- Direct Known Subclasses:
- DefaultGlobalScopeProvider, ImportUriGlobalScopeProvider, ResourceSetGlobalScopeProvider
public abstract class AbstractGlobalScopeProvider
- extends java.lang.Object
- implements IGlobalScopeProvider
- Author:
- Sebastian Zarnekow - Initial contribution and API, Sven Efftinge
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractGlobalScopeProvider
public AbstractGlobalScopeProvider()
getResourceDescriptions
public IResourceDescriptions getResourceDescriptions(org.eclipse.emf.ecore.resource.Resource resource)
setResourceDescriptionsProvider
public void setResourceDescriptionsProvider(ResourceDescriptionsProvider provider)
getScope
public IScope getScope(org.eclipse.emf.ecore.resource.Resource resource,
org.eclipse.emf.ecore.EReference reference)
getScope
public IScope getScope(org.eclipse.emf.ecore.resource.Resource resource,
org.eclipse.emf.ecore.EReference reference,
com.google.common.base.Predicate<IEObjectDescription> filter)
- Description copied from interface:
IGlobalScopeProvider
- Returns a global scope for the given context. The scope provides access to the
EObjectDescription
visible from the given Resource
according to the definition of the global scope hierarchy (which is usually defined by
IContainer.Manager
).
- Specified by:
getScope
in interface IGlobalScopeProvider
- Parameters:
resource
- the resource from which the global scope is looked at.reference
- the reference for which to construct a global scope.filter
- a filter used to filter down the elements contained in each scope. Scopes will only contain elements for which the filter returned true
.
- Returns:
IScope
representing the inner most IScope
for the
passed context and reference. Note for implementors: The result may not be null
.
Return IScope.NULLSCOPE
instead.
getScope
protected IScope getScope(org.eclipse.emf.ecore.resource.Resource resource,
boolean ignoreCase,
org.eclipse.emf.ecore.EClass type,
com.google.common.base.Predicate<IEObjectDescription> predicate)
isIgnoreCase
protected boolean isIgnoreCase(org.eclipse.emf.ecore.EReference reference)
setCaseInsensitivityHelper
public void setCaseInsensitivityHelper(ICaseInsensitivityHelper caseInsensitivityHelper)