Class ScopeBasedContentProvider
java.lang.Object
com._1c.g5.modeling.xtext.ui.viewers.ScopeBasedContentProvider
- All Implemented Interfaces:
IContentProvider
,IStructuredContentProvider
This implementation of
IStructuredContentProvider
handles
the case where the viewer input is an Pair<EObject, EReference>. Given EObject must be contained by resource.
This implementation tries to get appropriate IScopeProvider
registered for resource which contains given EObject.
With the help of this scope provider and input pair it gets scope and returns array of IEObjectDescription
s or
empty array if input arguments are wrong or there is no appropriate scope provider.
- Restriction:
- This class is not intended to be subclassed by clients.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
dispose()
This implementation does nothing.Object[]
getElements
(Object inputElement) static ScopeBasedContentProvider
Returns an instance of ScopeBasedContentProvider.void
inputChanged
(Viewer viewer, Object oldInput, Object newInput) This implementation does nothing.
-
Method Details
-
getInstance
Returns an instance of ScopeBasedContentProvider. Since instances of this class do not maintain any state, they can be shared between multiple clients.- Returns:
- an instance of ScopeBasedContentProvider
-
getElements
- Specified by:
getElements
in interfaceIStructuredContentProvider
-
inputChanged
This implementation does nothing.- Specified by:
inputChanged
in interfaceIContentProvider
-
dispose
public void dispose()This implementation does nothing.- Specified by:
dispose
in interfaceIContentProvider
-