|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.emf.ecore.resource.impl.ResourceFactoryImpl
org.eclipse.ocl.examples.pivot.resource.AbstractASResourceFactory
public abstract class AbstractASResourceFactory
AbstractASResourceFactory provides the abstract functionality for creating and maintaining OCL Abstract Syntax Resources.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.eclipse.emf.ecore.resource.Resource.Factory |
|---|
org.eclipse.emf.ecore.resource.Resource.Factory.Descriptor, org.eclipse.emf.ecore.resource.Resource.Factory.Registry |
| Field Summary | |
|---|---|
protected java.lang.String |
contentType
|
protected java.lang.String |
fileExtension
|
| Fields inherited from interface org.eclipse.ocl.examples.pivot.resource.ASResourceFactory |
|---|
CAN_HANDLE, CANNOT_HANDLE, MAY_HANDLE |
| Constructor Summary | |
|---|---|
protected |
AbstractASResourceFactory(java.lang.String contentType,
java.lang.String fileExtension)
|
| Method Summary | ||
|---|---|---|
void |
configure(org.eclipse.emf.ecore.resource.ResourceSet resourceSet)
Configure the MetaModelManager's external ResourceSet. |
|
protected void |
configureResource(ASResource asResource)
|
|
AS2MonikerVisitor |
createAS2MonikerVisitor(AS2Moniker as2moniker)
Create a visitor to compute a structural descriptor for an element. |
|
AS2XMIidVisitor |
createAS2XMIidVisitor(AS2XMIid as2id)
Create a visitor to compute the xmi:id value of an element. |
|
ASSaverLocateVisitor |
createASSaverLocateVisitor(ASSaver saver)
Create a visitor to locate orphan specializations. |
|
ASSaverNormalizeVisitor |
createASSaverNormalizeVisitor(ASSaver saver)
Create a visitor to normalize content. |
|
ASSaverResolveVisitor |
createASSaverResolveVisitor(ASSaver saver)
Create a visitor to resolve orphan specializations. |
|
PrettyPrintVisitor |
createPrettyPrintVisitor(PrettyPrinter prettyPrinter)
Create a visitor to provide a pretty printed representation of one or more elements in the resource. |
|
org.eclipse.emf.ecore.resource.Resource |
createResource(org.eclipse.emf.common.util.URI uri)
Creates an instance of the resource. |
|
ToStringVisitor |
createToStringVisitor(java.lang.StringBuilder s)
Create a visitor to provide a debug representation of one or more elements in the resource. |
|
|
getASElement(MetaModelManager metaModelManager,
java.lang.Class<T> pivotClass,
org.eclipse.emf.ecore.EObject eObject)
Return the OCL AS element corresponding to eObject using metaModelManager to supervise the correspondence and ensuring that the result is of asClass. |
|
java.lang.String |
getContentType()
Return the Content Type Identifier supported by this ASResourceFactory. |
|
org.eclipse.emf.ecore.EOperation |
getEOperation(ASResource asResource,
org.eclipse.emf.ecore.EObject eObject)
Return an EOperation for a pivot Operation if one is available. |
|
org.eclipse.emf.ecore.EReference |
getEReference(ASResource asResource,
org.eclipse.emf.ecore.EObject eObject)
|
|
int |
getHandlerPriority(org.eclipse.emf.ecore.EObject eObject)
Return a positive handler priority if this factory can handle creation of an OCL AS type from the available object, negative if it cannot. |
|
int |
getHandlerPriority(org.eclipse.emf.ecore.resource.Resource resource)
Return a positive handler priority if this factory can handle creation of an OCL AS resource from the available resource, negative if it cannot. |
|
int |
getHandlerPriority(org.eclipse.emf.common.util.URI uri)
Return a positive handler priority if this factory can handle creation of an OCL AS resource from the available URI, negative if it cannot. |
|
java.lang.String |
getMetamodelNsURI(org.eclipse.emf.ecore.EPackage ePackage)
Return a specific metamodel NsURI if ePackage has particular requirements as is the case for UML. |
|
org.eclipse.emf.common.util.URI |
getPackageURI(org.eclipse.emf.ecore.EObject eObject)
Return the URI of an eObject if it can be treated as a Package. |
|
Element |
importFromResource(MetaModelManager metaModelManager,
org.eclipse.emf.ecore.resource.Resource resource,
org.eclipse.emf.common.util.URI uri)
Return the root element in the Pivot resource resulting from import of the available resource. |
|
static void |
installContentHandler(int priority,
org.eclipse.emf.ecore.resource.ContentHandler contentHandler)
|
|
boolean |
isCompatibleResource(org.eclipse.emf.ecore.resource.Resource newResource,
org.eclipse.emf.ecore.resource.Resource oldResource)
Return true if newResource can be ignored in favour of an already loaded oldResource. |
|
java.lang.String |
toString()
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
@NonNull protected final java.lang.String contentType
@Nullable protected final java.lang.String fileExtension
| Constructor Detail |
|---|
protected AbstractASResourceFactory(@NonNull
java.lang.String contentType,
@Nullable
java.lang.String fileExtension)
| Method Detail |
|---|
public static void installContentHandler(int priority,
@NonNull
org.eclipse.emf.ecore.resource.ContentHandler contentHandler)
public void configure(@NonNull
org.eclipse.emf.ecore.resource.ResourceSet resourceSet)
ASResourceFactory
configure in interface ASResourceFactory
protected void configureResource(@NonNull
ASResource asResource)
@NonNull
public AS2MonikerVisitor createAS2MonikerVisitor(@NonNull
AS2Moniker as2moniker)
ASResourceFactory
createAS2MonikerVisitor in interface ASResourceFactory
@NonNull
public AS2XMIidVisitor createAS2XMIidVisitor(@NonNull
AS2XMIid as2id)
ASResourceFactory
createAS2XMIidVisitor in interface ASResourceFactory
@NonNull
public ASSaverLocateVisitor createASSaverLocateVisitor(@NonNull
ASSaver saver)
ASResourceFactory
createASSaverLocateVisitor in interface ASResourceFactory
@NonNull
public ASSaverNormalizeVisitor createASSaverNormalizeVisitor(@NonNull
ASSaver saver)
ASResourceFactory
createASSaverNormalizeVisitor in interface ASResourceFactory
@NonNull
public ASSaverResolveVisitor createASSaverResolveVisitor(@NonNull
ASSaver saver)
ASResourceFactory
createASSaverResolveVisitor in interface ASResourceFactory
@NonNull
public PrettyPrintVisitor createPrettyPrintVisitor(@NonNull
PrettyPrinter prettyPrinter)
ASResourceFactory
createPrettyPrintVisitor in interface ASResourceFactory
@NonNull
public ToStringVisitor createToStringVisitor(@NonNull
java.lang.StringBuilder s)
ASResourceFactory
createToStringVisitor in interface ASResourceFactorypublic org.eclipse.emf.ecore.resource.Resource createResource(org.eclipse.emf.common.util.URI uri)
createResource in interface org.eclipse.emf.ecore.resource.Resource.FactorycreateResource in class org.eclipse.emf.ecore.resource.impl.ResourceFactoryImpl
@Nullable
public <T extends Element> T getASElement(@NonNull
MetaModelManager metaModelManager,
@NonNull
java.lang.Class<T> pivotClass,
@NonNull
org.eclipse.emf.ecore.EObject eObject)
throws ParserException
ASResourceFactory
getASElement in interface ASResourceFactoryParserException@NonNull public java.lang.String getContentType()
ASResourceFactory
getContentType in interface ASResourceFactory
@Nullable
public org.eclipse.emf.ecore.EOperation getEOperation(@NonNull
ASResource asResource,
@NonNull
org.eclipse.emf.ecore.EObject eObject)
ASResourceFactory
getEOperation in interface ASResourceFactory
@Nullable
public org.eclipse.emf.ecore.EReference getEReference(@NonNull
ASResource asResource,
@NonNull
org.eclipse.emf.ecore.EObject eObject)
getEReference in interface ASResourceFactory
public int getHandlerPriority(@NonNull
org.eclipse.emf.ecore.EObject eObject)
ASResourceFactory
getHandlerPriority in interface ASResourceFactory
public int getHandlerPriority(@NonNull
org.eclipse.emf.ecore.resource.Resource resource)
ASResourceFactory
getHandlerPriority in interface ASResourceFactory
public int getHandlerPriority(@NonNull
org.eclipse.emf.common.util.URI uri)
ASResourceFactory
getHandlerPriority in interface ASResourceFactory
@Nullable
public java.lang.String getMetamodelNsURI(@NonNull
org.eclipse.emf.ecore.EPackage ePackage)
ASResourceFactory
getMetamodelNsURI in interface ASResourceFactory
@Nullable
public org.eclipse.emf.common.util.URI getPackageURI(@NonNull
org.eclipse.emf.ecore.EObject eObject)
ASResourceFactory
getPackageURI in interface ASResourceFactory
@Nullable
public Element importFromResource(@NonNull
MetaModelManager metaModelManager,
@NonNull
org.eclipse.emf.ecore.resource.Resource resource,
@Nullable
org.eclipse.emf.common.util.URI uri)
throws ParserException
ASResourceFactory
importFromResource in interface ASResourceFactoryParserException
public boolean isCompatibleResource(@NonNull
org.eclipse.emf.ecore.resource.Resource newResource,
@NonNull
org.eclipse.emf.ecore.resource.Resource oldResource)
ASResourceFactory
isCompatibleResource in interface ASResourceFactory@NonNull public java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||