org.eclipse.gmt.umlx.registry.util
Class AbstractModelResolver

java.lang.Object
  extended by org.eclipse.gmt.umlx.registry.util.AbstractModelResolver
All Implemented Interfaces:
ModelResolver
Direct Known Subclasses:
ModelFileResolver, ModelResourceResolver

public abstract class AbstractModelResolver
extends java.lang.Object
implements ModelResolver


Method Summary
 org.eclipse.emf.ecore.resource.Resource getResource(org.eclipse.emf.common.util.URI uri, boolean loadOnDemand)
           
 org.eclipse.emf.ecore.resource.ResourceSet getResourceSet()
           
 org.eclipse.emf.common.util.URI getURI(java.lang.String modelName)
          Return the (Ecore) URI suitable for getting the (Ecore) resource defined by the modelName of a (Workspace) resource.
 org.eclipse.emf.common.util.URI getURI(java.net.URI uri)
          Return the (Ecore) URI suitable for getting the (Ecore) resource defined by the (java.net.URI) uri of a (Workspace) resource.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.gmt.umlx.registry.util.ModelResolver
getURI
 

Method Detail

getResource

public org.eclipse.emf.ecore.resource.Resource getResource(org.eclipse.emf.common.util.URI uri,
                                                           boolean loadOnDemand)
                                                    throws java.lang.Exception
Specified by:
getResource in interface ModelResolver
Throws:
java.lang.Exception

getResourceSet

public org.eclipse.emf.ecore.resource.ResourceSet getResourceSet()
Specified by:
getResourceSet in interface ModelResolver

getURI

public org.eclipse.emf.common.util.URI getURI(java.lang.String modelName)
Description copied from interface: ModelResolver
Return the (Ecore) URI suitable for getting the (Ecore) resource defined by the modelName of a (Workspace) resource. This is just a convenience form of getURI(resource, new ModelNameAccessor(modelName)).

Specified by:
getURI in interface ModelResolver
Parameters:
modelName - the name of the model to be located.
Returns:
the Ecore URI

getURI

public org.eclipse.emf.common.util.URI getURI(java.net.URI uri)
Description copied from interface: ModelResolver
Return the (Ecore) URI suitable for getting the (Ecore) resource defined by the (java.net.URI) uri of a (Workspace) resource. This is just a convenience form of getURI(resource, new URIAccessor(uri)).

Specified by:
getURI in interface ModelResolver
Returns:
the Ecore URI