org.eclipse.emf.emfstore.internal.ecore
Class EDatatypeIdResolver

java.lang.Object
  extended by org.eclipse.emf.emfstore.internal.ecore.EDatatypeIdResolver
All Implemented Interfaces:
ESSingletonIdResolver

public class EDatatypeIdResolver
extends Object
implements ESSingletonIdResolver

An implementation of a ESSingletonIdResolver that treats all EDataTypes as singletons.

Author:
emueller

Constructor Summary
EDatatypeIdResolver()
          Default constructor.
 
Method Summary
 org.eclipse.emf.ecore.EObject getSingleton(ESModelElementId singletonId)
          Returns the singleton which belongs to the given ESModelElementId.
 ESModelElementId getSingletonModelElementId(org.eclipse.emf.ecore.EObject singleton)
          Returns the ID for the given singleton EObject.
 boolean isSingleton(org.eclipse.emf.ecore.EObject eDataType)
          Determines whether the given EObject is a singleton.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EDatatypeIdResolver

public EDatatypeIdResolver()
Default constructor.

Method Detail

getSingleton

public org.eclipse.emf.ecore.EObject getSingleton(ESModelElementId singletonId)
Returns the singleton which belongs to the given ESModelElementId.

Specified by:
getSingleton in interface ESSingletonIdResolver
Parameters:
singletonId - a ESModelElementId
Returns:
the singleton EObject that belongs to the given ESModelElementId

getSingletonModelElementId

public ESModelElementId getSingletonModelElementId(org.eclipse.emf.ecore.EObject singleton)
Returns the ID for the given singleton EObject.

Specified by:
getSingletonModelElementId in interface ESSingletonIdResolver
Parameters:
singleton - the singleton EObject whose ESModelElementId should get retrieved
Returns:
the ESModelElementId of the the singleton object or null if the given EObject is not a singleton, is not an instance of EDataType or is null

isSingleton

public boolean isSingleton(org.eclipse.emf.ecore.EObject eDataType)
Determines whether the given EObject is a singleton.

Specified by:
isSingleton in interface ESSingletonIdResolver
Parameters:
eDataType - the EObject to check
Returns:
true, if the given EObject is a singleton


Copyright © 2015. All Rights Reserved.