Package org.eclipse.xtext.resource.impl
Class ResourceSetBasedResourceDescriptions
- java.lang.Object
-
- org.eclipse.xtext.resource.impl.AbstractCompoundSelectable
-
- org.eclipse.xtext.resource.impl.ResourceSetBasedResourceDescriptions
-
- All Implemented Interfaces:
IResourceDescriptions,IResourceDescriptions.IContextAware,IResourceDescriptions.IResourceSetAware,ISelectable
- Direct Known Subclasses:
LiveShadowedResourceDescriptions
public class ResourceSetBasedResourceDescriptions extends AbstractCompoundSelectable implements IResourceDescriptions.IContextAware, IResourceDescriptions.IResourceSetAware
- Since:
- 2.5
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.eclipse.xtext.resource.IResourceDescriptions
IResourceDescriptions.IContextAware, IResourceDescriptions.IResourceSetAware, IResourceDescriptions.NullImpl
-
-
Constructor Summary
Constructors Constructor Description ResourceSetBasedResourceDescriptions()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Iterable<IResourceDescription>getAllResourceDescriptions()protected ResourceDescriptionsDatagetData()java.lang.Iterable<IEObjectDescription>getExportedObjects()java.lang.Iterable<IEObjectDescription>getExportedObjects(org.eclipse.emf.ecore.EClass type, QualifiedName qualifiedName, boolean ignoreCase)java.lang.Iterable<IEObjectDescription>getExportedObjectsByObject(org.eclipse.emf.ecore.EObject object)java.lang.Iterable<IEObjectDescription>getExportedObjectsByType(org.eclipse.emf.ecore.EClass type)IResourceDescriptiongetResourceDescription(org.eclipse.emf.common.util.URI uri)Returns the resource descriptions for the given URI.org.eclipse.emf.ecore.resource.ResourceSetgetResourceSet()protected java.lang.Iterable<? extends ISelectable>getSelectables()protected booleanhasDescription(org.eclipse.emf.common.util.URI uri)booleanisEmpty()Clients may want to check the selectable to skip its processing in case it is empty.voidsetContext(org.eclipse.emf.common.notify.Notifier ctx)protected voidsetData(ResourceDescriptionsData data)voidsetRegistry(IResourceServiceProvider.Registry registry)java.lang.StringtoString()
-
-
-
Method Detail
-
setRegistry
public void setRegistry(IResourceServiceProvider.Registry registry)
-
getResourceSet
public org.eclipse.emf.ecore.resource.ResourceSet getResourceSet()
- Specified by:
getResourceSetin interfaceIResourceDescriptions.IResourceSetAware
-
getAllResourceDescriptions
public java.lang.Iterable<IResourceDescription> getAllResourceDescriptions()
- Specified by:
getAllResourceDescriptionsin interfaceIResourceDescriptions
-
getSelectables
protected java.lang.Iterable<? extends ISelectable> getSelectables()
- Specified by:
getSelectablesin classAbstractCompoundSelectable
-
isEmpty
public boolean isEmpty()
Description copied from interface:ISelectableClients may want to check the selectable to skip its processing in case it is empty. Implementations should be fast and not require expensive precalculation. Selectable may returnfalseif it is too expensive to compute the actual result.- Specified by:
isEmptyin interfaceISelectable- Overrides:
isEmptyin classAbstractCompoundSelectable- Returns:
trueif the selectable does not provide any descriptions.
-
hasDescription
protected boolean hasDescription(org.eclipse.emf.common.util.URI uri)
- Since:
- 2.1
-
getResourceDescription
public IResourceDescription getResourceDescription(org.eclipse.emf.common.util.URI uri)
Description copied from interface:IResourceDescriptionsReturns the resource descriptions for the given URI.- Specified by:
getResourceDescriptionin interfaceIResourceDescriptions
-
setContext
public void setContext(org.eclipse.emf.common.notify.Notifier ctx)
- Specified by:
setContextin interfaceIResourceDescriptions.IContextAware
-
getData
protected ResourceDescriptionsData getData()
-
setData
protected void setData(ResourceDescriptionsData data)
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
getExportedObjects
public java.lang.Iterable<IEObjectDescription> getExportedObjects()
- Specified by:
getExportedObjectsin interfaceISelectable- Overrides:
getExportedObjectsin classAbstractCompoundSelectable- Returns:
- all exported elements. May not be
null. - Since:
- 2.5
-
getExportedObjectsByType
public java.lang.Iterable<IEObjectDescription> getExportedObjectsByType(org.eclipse.emf.ecore.EClass type)
- Specified by:
getExportedObjectsByTypein interfaceISelectable- Overrides:
getExportedObjectsByTypein classAbstractCompoundSelectable- Returns:
- all elements which match the given type. May not be
null. - Since:
- 2.5
-
getExportedObjects
public java.lang.Iterable<IEObjectDescription> getExportedObjects(org.eclipse.emf.ecore.EClass type, QualifiedName qualifiedName, boolean ignoreCase)
- Specified by:
getExportedObjectsin interfaceISelectable- Overrides:
getExportedObjectsin classAbstractCompoundSelectable- Returns:
- all elements which match the given qualified name and type. May not be
null. - Since:
- 2.5
-
getExportedObjectsByObject
public java.lang.Iterable<IEObjectDescription> getExportedObjectsByObject(org.eclipse.emf.ecore.EObject object)
- Specified by:
getExportedObjectsByObjectin interfaceISelectable- Overrides:
getExportedObjectsByObjectin classAbstractCompoundSelectable- Returns:
- all elements which match the given instance. May not be
null. - Since:
- 2.5
-
-