org.eclipse.emf.ecore.impl
Class EClassifierImpl

java.lang.Object
  extended byorg.eclipse.emf.common.notify.impl.BasicNotifierImpl
      extended byorg.eclipse.emf.ecore.impl.BasicEObjectImpl
          extended byorg.eclipse.emf.ecore.impl.EObjectImpl
              extended byorg.eclipse.emf.ecore.impl.EModelElementImpl
                  extended byorg.eclipse.emf.ecore.impl.ENamedElementImpl
                      extended byorg.eclipse.emf.ecore.impl.EClassifierImpl
All Implemented Interfaces:
BasicExtendedMetaData.EClassifierExtendedMetaData.Holder, EClassifier, EModelElement, ENamedElement, EObject, InternalEObject, Notifier
Direct Known Subclasses:
EClassImpl, EDataTypeImpl

public abstract class EClassifierImpl
extends ENamedElementImpl
implements EClassifier, BasicExtendedMetaData.EClassifierExtendedMetaData.Holder

An implementation of the model object 'EMeta Object'.


Nested Class Summary
 
Nested classes inherited from class org.eclipse.emf.ecore.impl.BasicEObjectImpl
BasicEObjectImpl.EPropertiesHolder, BasicEObjectImpl.EPropertiesHolderImpl
 
Nested classes inherited from class org.eclipse.emf.common.notify.impl.BasicNotifierImpl
BasicNotifierImpl.EAdapterList
 
Nested classes inherited from class org.eclipse.emf.ecore.InternalEObject
InternalEObject.EStore
 
Field Summary
protected static Object DEFAULT_VALUE_EDEFAULT
          The default value of the 'Default Value' attribute
protected  BasicExtendedMetaData.EClassifierExtendedMetaData eClassifierExtendedMetaData
           
protected  String generatedInstanceClassName
           
protected static Class INSTANCE_CLASS_EDEFAULT
          The default value of the 'Instance Class' attribute.
protected static String INSTANCE_CLASS_NAME_EDEFAULT
          The default value of the 'Instance Class Name' attribute
protected  Class instanceClass
          The cached value of the 'Instance Class' attribute.
protected  String instanceClassName
          The cached value of the 'Instance Class Name' attribute
protected  int metaObjectID
           
 
Fields inherited from class org.eclipse.emf.ecore.impl.ENamedElementImpl
name, NAME_EDEFAULT
 
Fields inherited from class org.eclipse.emf.ecore.impl.EModelElementImpl
eAnnotations, EFROZEN, ELAST_EMODEL_ELEMENT_FLAG
 
Fields inherited from class org.eclipse.emf.ecore.impl.EObjectImpl
eAdapters, eContainer, eContainerFeatureID, EDELIVER, EDYNAMIC_CLASS, eFlags, ELAST_EOBJECT_FLAG, ELAST_NOTIFIER_FLAG, eProperties, EPROXY
 
Fields inherited from interface org.eclipse.emf.ecore.InternalEObject
EOPPOSITE_FEATURE_BASE
 
Constructor Summary
protected EClassifierImpl()
           
 
Method Summary
protected  boolean dynamicIsInstance(EObject eObject)
           
 NotificationChain eBasicRemoveFromContainer(NotificationChain msgs)
           
 Object eGet(EStructuralFeature eFeature, boolean resolve)
           
 NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, Class baseClass, NotificationChain msgs)
           
 NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, Class baseClass, NotificationChain msgs)
           
 boolean eIsSet(EStructuralFeature eFeature)
           
 void eSet(EStructuralFeature eFeature, Object newValue)
           
protected  EClass eStaticClass()
           
 void eUnset(EStructuralFeature eFeature)
           
protected  Class getClassForName(String name)
          Returns the Class object associated with the class or interface with the given name, as from a Class.forName(String) call; however, if this classifier belongs to a package, that package's class loader is used.
 int getClassifierID()
           
 Object getDefaultValue()
          Returns the value of the 'Default Value' attribute
 EPackage getEPackage()
           
 BasicExtendedMetaData.EClassifierExtendedMetaData getExtendedMetaData()
           
 Class getInstanceClass()
          Returns the value of the 'Instance Class' attribute
 Class getInstanceClassGen()
           
 String getInstanceClassName()
          Returns the value of the 'Instance Class Name' attribute
 String getInstanceClassNameGen()
           
protected  Class getPrimitiveOrArrayClass()
           
 boolean isInstance(Object object)
          Returns whether the object is an instance of this classifier.
 void setClassifierID(int id)
           
 void setExtendedMetaData(BasicExtendedMetaData.EClassifierExtendedMetaData eClassifierExtendedMetaData)
           
 void setGeneratedInstanceClass(boolean isGenerated)
           
 void setInstanceClass(Class value)
          Sets the value of the 'Instance Class' attribute.
 void setInstanceClassGen(Class newInstanceClass)
           
 void setInstanceClassName(String value)
          Sets the value of the 'Instance Class Name' attribute
 void setInstanceClassNameGen(String newInstanceClassName)
           
 String toString()
           
 
Methods inherited from class org.eclipse.emf.ecore.impl.ENamedElementImpl
getName, getNameGen, setName
 
Methods inherited from class org.eclipse.emf.ecore.impl.EModelElementImpl
eObjectForURIFragmentSegment, eURIFragmentSegment, freeze, getEAnnotation, getEAnnotations, isFrozen
 
Methods inherited from class org.eclipse.emf.ecore.impl.EObjectImpl
eAdapters, eBasicAdapters, eBasicProperties, eBasicSetContainer, eClass, eContainerFeatureID, eDeliver, eInternalContainer, eIsProxy, eProperties, eSetClass, eSetDeliver, eSetProxyURI
 
Methods inherited from class org.eclipse.emf.ecore.impl.BasicEObjectImpl
eAllContents, eBaseStructuralFeatureID, eBasicSetContainer, eContainer, eContainingFeature, eContainmentFeature, eContains, eContents, eCrossReferences, eDerivedStructuralFeatureID, eDerivedStructuralFeatureID, eDirectResource, eDynamicBasicRemoveFromContainer, eDynamicClass, eDynamicFeature, eDynamicFeatureID, eDynamicGet, eDynamicInverseAdd, eDynamicInverseRemove, eDynamicIsSet, eDynamicSet, eDynamicUnset, eGet, eHasSettings, eInternalResource, eOpenGet, eOpenIsSet, eOpenSet, eOpenUnset, eProxyURI, eResolveProxy, eResource, eSetResource, eSetStore, eSetting, eSettingDelegate, eSettings, eStaticFeatureCount, eStore
 
Methods inherited from class org.eclipse.emf.common.notify.impl.BasicNotifierImpl
eNotificationRequired, eNotify
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.eclipse.emf.ecore.ENamedElement
getName, setName
 
Methods inherited from interface org.eclipse.emf.ecore.EModelElement
getEAnnotation, getEAnnotations
 
Methods inherited from interface org.eclipse.emf.ecore.EObject
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eIsProxy, eResource
 
Methods inherited from interface org.eclipse.emf.common.notify.Notifier
eAdapters, eDeliver, eNotify, eSetDeliver
 
Methods inherited from interface org.eclipse.emf.ecore.InternalEObject
eNotificationRequired
 

Field Detail

metaObjectID

protected int metaObjectID

INSTANCE_CLASS_NAME_EDEFAULT

protected static final String INSTANCE_CLASS_NAME_EDEFAULT
The default value of the 'Instance Class Name' attribute.

See Also:
getInstanceClassName()

instanceClassName

protected String instanceClassName
The cached value of the 'Instance Class Name' attribute.

See Also:
getInstanceClassName()

generatedInstanceClassName

protected String generatedInstanceClassName

INSTANCE_CLASS_EDEFAULT

protected static final Class INSTANCE_CLASS_EDEFAULT
The default value of the 'Instance Class' attribute.

See Also:
getInstanceClass()

DEFAULT_VALUE_EDEFAULT

protected static final Object DEFAULT_VALUE_EDEFAULT
The default value of the 'Default Value' attribute.

See Also:
getDefaultValue()

instanceClass

protected Class instanceClass
The cached value of the 'Instance Class' attribute.

See Also:
getInstanceClass()

eClassifierExtendedMetaData

protected BasicExtendedMetaData.EClassifierExtendedMetaData eClassifierExtendedMetaData
Constructor Detail

EClassifierImpl

protected EClassifierImpl()

Method Detail

eStaticClass

protected EClass eStaticClass()

Overrides:
eStaticClass in class ENamedElementImpl

getClassifierID

public int getClassifierID()

Specified by:
getClassifierID in interface EClassifier
Returns:
the relative ID.

eInverseAdd

public NotificationChain eInverseAdd(InternalEObject otherEnd,
                                     int featureID,
                                     Class baseClass,
                                     NotificationChain msgs)

Specified by:
eInverseAdd in interface InternalEObject
Overrides:
eInverseAdd in class ENamedElementImpl

eInverseRemove

public NotificationChain eInverseRemove(InternalEObject otherEnd,
                                        int featureID,
                                        Class baseClass,
                                        NotificationChain msgs)

Specified by:
eInverseRemove in interface InternalEObject
Overrides:
eInverseRemove in class ENamedElementImpl

setClassifierID

public void setClassifierID(int id)

isInstance

public boolean isInstance(Object object)
Returns whether the object is an instance of this classifier.

Specified by:
isInstance in interface EClassifier
Parameters:
object - the object in question.
Returns:
whether the object is an instance.
See Also:
Class.isInstance(java.lang.Object)

dynamicIsInstance

protected boolean dynamicIsInstance(EObject eObject)

eGet

public Object eGet(EStructuralFeature eFeature,
                   boolean resolve)

Specified by:
eGet in interface EObject
Overrides:
eGet in class ENamedElementImpl

eIsSet

public boolean eIsSet(EStructuralFeature eFeature)

Specified by:
eIsSet in interface EObject
Overrides:
eIsSet in class ENamedElementImpl

eSet

public void eSet(EStructuralFeature eFeature,
                 Object newValue)

Specified by:
eSet in interface EObject
Overrides:
eSet in class ENamedElementImpl

eUnset

public void eUnset(EStructuralFeature eFeature)

Specified by:
eUnset in interface EObject
Overrides:
eUnset in class ENamedElementImpl

getInstanceClassNameGen

public String getInstanceClassNameGen()


getInstanceClassName

public String getInstanceClassName()
Description copied from interface: EClassifier
Returns the value of the 'Instance Class Name' attribute.

It represents the name of the Java instance class that this meta object represents.

Specified by:
getInstanceClassName in interface EClassifier
Returns:
the value of the 'Instance Class Name' attribute.
See Also:
EClassifier.getInstanceClass(), EClassifier.setInstanceClassName(String), EcorePackage.getEClassifier_InstanceClassName()

setGeneratedInstanceClass

public void setGeneratedInstanceClass(boolean isGenerated)

setInstanceClassName

public void setInstanceClassName(String value)
Description copied from interface: EClassifier
Sets the value of the 'Instance Class Name' attribute.

Specified by:
setInstanceClassName in interface EClassifier
Parameters:
value - the new value of the 'Instance Class Name' attribute.
See Also:
EClassifier.getInstanceClassName()

setInstanceClassNameGen

public void setInstanceClassNameGen(String newInstanceClassName)


getInstanceClass

public Class getInstanceClass()
Description copied from interface: EClassifier
Returns the value of the 'Instance Class' attribute.

It represents the actual Java instance class that this meta object represents.

Specified by:
getInstanceClass in interface EClassifier
Returns:
the value of the 'Instance Class' attribute.
See Also:
EClassifier.setInstanceClass(Class), EcorePackage.getEClassifier_InstanceClass()

getClassForName

protected Class getClassForName(String name)
                         throws ClassNotFoundException
Returns the Class object associated with the class or interface with the given name, as from a Class.forName(String) call; however, if this classifier belongs to a package, that package's class loader is used. Since the package may be model-specific code in another plug-in, its class loader may be able to see classes that Ecore's can't.

Throws:
ClassNotFoundException

getPrimitiveOrArrayClass

protected Class getPrimitiveOrArrayClass()

getInstanceClassGen

public Class getInstanceClassGen()

setInstanceClass

public void setInstanceClass(Class value)
Description copied from interface: EClassifier
Sets the value of the 'Instance Class' attribute.

Specified by:
setInstanceClass in interface EClassifier
Parameters:
value - the new value of the 'Instance Class' attribute.
See Also:
EClassifier.getInstanceClass()

setInstanceClassGen

public void setInstanceClassGen(Class newInstanceClass)

getDefaultValue

public Object getDefaultValue()
Description copied from interface: EClassifier
Returns the value of the 'Default Value' attribute.

The default value for the type, in the Java sense. For primitive types, it will be the Java primitive default wrapped appropriately. For enums, it will be the first enumerator. And for all other types derived from java.lang.Object, it will be null.

Specified by:
getDefaultValue in interface EClassifier
Returns:
the value of the 'Default Value' attribute.
See Also:
EcorePackage.getEClassifier_DefaultValue()

getEPackage

public EPackage getEPackage()

Specified by:
getEPackage in interface EClassifier
Returns:
the value of the 'EPackage' container reference.
See Also:
EcorePackage.getEClassifier_EPackage(), EPackage.getEClassifiers()

toString

public String toString()

Overrides:
toString in class ENamedElementImpl

eBasicRemoveFromContainer

public NotificationChain eBasicRemoveFromContainer(NotificationChain msgs)

Specified by:
eBasicRemoveFromContainer in interface InternalEObject
Overrides:
eBasicRemoveFromContainer in class BasicEObjectImpl

getExtendedMetaData

public BasicExtendedMetaData.EClassifierExtendedMetaData getExtendedMetaData()
Specified by:
getExtendedMetaData in interface BasicExtendedMetaData.EClassifierExtendedMetaData.Holder

setExtendedMetaData

public void setExtendedMetaData(BasicExtendedMetaData.EClassifierExtendedMetaData eClassifierExtendedMetaData)
Specified by:
setExtendedMetaData in interface BasicExtendedMetaData.EClassifierExtendedMetaData.Holder

Copyright 2001-2004 IBM Corporation and others.
All Rights Reserved.