@Beta public final class NotLoadingResourceSet extends ResourceSetImpl implements DisposableResourceSet
StorageTraversal, and only those
resources that are part of the traversal will be loaded. This will allow us to resolve the proxies between
these "traversed" resources.
This resource set will prevent loading any resources that is not part of the initial traversal. The only
exception to this rule is if one of the registered ILoadOnDemandPolicy says otherwise. Users should
not try to add more resources into this resource set using any of the createResource methods.
ResourceSetImpl.MappedResourceLocator, ResourceSetImpl.ResourceLocator, ResourceSetImpl.ResourcesEList<E extends Object & Resource>BasicNotifierImpl.EAdapterList<E extends Object & Adapter>, BasicNotifierImpl.EObservableAdapterListadapterFactories, loadOptions, packageRegistry, resourceFactoryRegistry, resourceLocator, resources, uriConverter, uriResourceMapeAdapters, EDELIVER, eFlags, ELAST_NOTIFIER_FLAGRESOURCE_SET__RESOURCES| Modifier and Type | Method and Description |
|---|---|
static NotLoadingResourceSet |
create(StorageTraversal traversals,
IProgressMonitor monitor,
ResourceSetHookRegistry resourceSetHookRegistry)
Constructs a resource set to contain the resources described by the given traversals.
|
Resource |
createResource(URI uri,
String contentType) |
protected void |
demandLoadHelper(Resource resource) |
void |
dispose()
This method should be called when the resource set is no longer needed.
|
TreeIterator<Notifier> |
getAllContents() |
EObject |
getEObject(URI uri,
boolean loadOnDemand) |
Resource |
getResource(URI uri,
boolean loadOnDemand) |
EList<Resource> |
getResources() |
protected void |
handleDemandLoadException(Resource resource,
IOException exception) |
createResource, delegatedGetResource, demandCreateResource, demandLoad, getAdapterFactories, getLoadOptions, getPackageRegistry, getResourceFactoryRegistry, getURIConverter, getURIResourceMap, setPackageRegistry, setResourceFactoryRegistry, setURIConverter, setURIResourceMap, toStringeAdapters, eBasicAdapters, eDeliver, eSetDelivereBasicAdapterArray, eBasicHasAdapters, eNotificationRequired, eNotifyclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitcreateResource, getAdapterFactories, getLoadOptions, getPackageRegistry, getResourceFactoryRegistry, getURIConverter, setPackageRegistry, setResourceFactoryRegistry, setURIConvertereAdapters, eDeliver, eNotify, eSetDeliverpublic static NotLoadingResourceSet create(StorageTraversal traversals, IProgressMonitor monitor, ResourceSetHookRegistry resourceSetHookRegistry)
traversals - All traversals we are to load.monitor - the monitor to which progress will be reported.resourceSetHookRegistry - A registry of IResourceSetHooks that potentialy can hook on the new
ResourceSet (can be null if none).protected void demandLoadHelper(Resource resource)
demandLoadHelper in class ResourceSetImplResourceSetImpl.demandLoadHelper(org.eclipse.emf.ecore.resource.Resource)protected void handleDemandLoadException(Resource resource, IOException exception)
public Resource getResource(URI uri, boolean loadOnDemand)
getResource in interface ResourceSetgetResource in class ResourceSetImplResourceSetImpl.getResource(org.eclipse.emf.common.util.URI,
boolean)public void dispose()
dispose in interface DisposableResourceSetDisposableResourceSet.dispose()public Resource createResource(URI uri, String contentType)
createResource in interface ResourceSetcreateResource in class ResourceSetImplResourceSetImpl.createResource(org.eclipse.emf.common.util.URI,
java.lang.String)public EObject getEObject(URI uri, boolean loadOnDemand)
getEObject in interface ResourceSetgetEObject in class ResourceSetImplResourceSetImpl.getEObject(org.eclipse.emf.common.util.URI,
boolean)public TreeIterator<Notifier> getAllContents()
getAllContents in interface ResourceSetgetAllContents in class ResourceSetImplResourceSetImpl.getAllContents()public EList<Resource> getResources()
getResources in interface ResourceSetgetResources in class ResourceSetImplResourceSetImpl.getResources()
Copyright (c) 2006, 2014 Obeo and others. All rights reserved.