org.eclipse.emf.codegen.ecore.genmodel.impl
Class GenBaseImpl

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.codegen.ecore.genmodel.impl.GenBaseImpl
All Implemented Interfaces:
EObject, GenBase, InternalEObject, Notifier
Direct Known Subclasses:
GenAnnotationImpl, GenClassifierImpl, GenEnumLiteralImpl, GenModelImpl, GenPackageImpl, GenTypedElementImpl

public abstract class GenBaseImpl
extends EObjectImpl
implements GenBase

An implementation of the model object 'Gen Base'.

The following features are implemented:


Nested Class Summary
protected static interface GenBaseImpl.AnnotationFilter
           
protected static class GenBaseImpl.AnnotationFilterImpl
           
static class GenBaseImpl.ColorInformation
          Deprecated. In EMF 2.2, this moved to GIFEmitter. This copy will be removed after 2.2.
protected static class GenBaseImpl.EclipseUtil
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalents to the methods in this class. This class will be removed after 2.2.
protected static class GenBaseImpl.GenAnnotationCopier
           
protected static interface GenBaseImpl.GenClassFilter
           
protected static interface GenBaseImpl.GenConstraintFilter
           
protected static interface GenBaseImpl.GenFeatureFilter
           
protected static interface GenBaseImpl.GenOperationFilter
           
protected static class GenBaseImpl.GIFEmitter
          Deprecated. In EMF 2.2, this moved to GIFEmitter. This copy will be removed after 2.2.
protected  class GenBaseImpl.UniqueNameHelper
           
 
Nested classes inherited from class org.eclipse.emf.ecore.impl.BasicEObjectImpl
BasicEObjectImpl.EPropertiesHolder, BasicEObjectImpl.EPropertiesHolderBaseImpl, 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 GenBaseImpl.AnnotationFilter DEFAULT_ANNOTATION_FILTER
           
protected static GenPackage ecoreGenPackage
           
protected static URI EMPTY_URI
          Deprecated. in EMF 2.2
protected  EList genAnnotations
          The cached value of the 'Gen Annotations' containment reference list
protected static URI PLATFORM_RESOURCE_URI
          Deprecated. in EMF 2.2
protected static GenPackage xmlNamespaceGenPackage
           
protected static GenPackage xmlTypeGenPackage
           
 
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 class org.eclipse.emf.ecore.impl.BasicEObjectImpl
EVIRTUAL_GET, EVIRTUAL_IS_SET, EVIRTUAL_NO_VALUE, EVIRTUAL_SET, EVIRTUAL_UNSET
 
Fields inherited from interface org.eclipse.emf.ecore.InternalEObject
EOPPOSITE_FEATURE_BASE
 
Constructor Summary
protected GenBaseImpl()
           
 
Method Summary
protected  void addNonDuplicates(Collection target, Collection source, Set noDupSet)
           
protected  void appendAnnotationInfo(StringBuffer result, boolean qualified, EModelElement eModelElement, GenBaseImpl.AnnotationFilter annotationFilter)
           
protected  void appendAnnotationInfo(StringBuffer result, EModelElement eModelElement)
           
protected  void appendAnnotationInfo(StringBuffer result, EModelElement eModelElement, GenBaseImpl.AnnotationFilter annotationFilter)
           
protected  void appendLineBreak(StringBuffer result)
           
protected  void appendModelSetting(StringBuffer result, String name, String value)
           
protected  void appendModelSetting(StringBuffer result, String qualifier, String name, String value)
           
 boolean canGenerate()
           
 boolean canGenerateEdit()
           
 boolean canGenerateEditor()
           
 boolean canGenerateSchema()
          Deprecated. In EMF 2.2, schema generation is properly done via a model exporter. This method will be removed after 2.2.
 boolean canGenerateTests()
           
 String capName(String name)
           
protected  List collectGenClasses(List eClasses, GenBaseImpl.GenClassFilter filter)
          Iterate over the specified eClasses list, finding the GenClass corresponding to each EClass.
protected  List collectGenConstraints(List genClassifiers, List genConstraints, GenBaseImpl.GenConstraintFilter filter)
          Iterate over the lists returned by calling getGenConstraints() on items in the list of genClassifiers, and then over the list of genConstraints.
protected  List collectGenFeatures(List genClasses, List genFeatures, GenBaseImpl.GenFeatureFilter filter)
          Iterate over the lists returned by calling getGenFeatures() on items in the list of genClasses, and then over the list of genFeatures.
protected  List collectGenOperations(List genClasses, List genOperations, GenBaseImpl.GenOperationFilter filter)
          Iterate over the lists returned by calling getGenOperations() on items in the list of genClasses, and then over the list of genOperations.
 InputStream createInputStream(URI uri)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  Monitor createMonitor(Monitor monitor, int ticks)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
 OutputStream createOutputStream(URI uri)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
 Object eGet(int featureID, boolean resolve, boolean coreType)
           
 NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs)
           
 NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs)
           
 boolean eIsSet(int featureID)
           
 EObject eObjectForURIFragmentSegment(String uriFragmentSegment)
          Returns the object resolved by the fragment segment.
protected static String escapeString(String s, String additionalCharactersToEscape)
           
 void eSet(int featureID, Object newValue)
           
protected  EClass eStaticClass()
           
 void eUnset(int featureID)
           
 String eURIFragmentSegment(EStructuralFeature eStructuralFeature, EObject eObject)
          Returns the fragment segment that, when passed to eObjectForURIFragmentSegment, will resolve to the given object in this object's given feature.
 boolean exists(URI uri)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  List filterGenClasses(List genClasses, GenBaseImpl.GenClassFilter filter)
          Return all GenClasses in the specified genClasses list that are accepted by filter; all are accepted if filter is null.
protected  GenClass findGenClass(EClass eClass)
           
protected  GenClassifier findGenClassifier(EClassifier eClassifier)
           
protected  GenDataType findGenDataType(EDataType eDataType)
           
protected  GenEnum findGenEnum(EEnum eEnum)
           
protected  GenFeature findGenFeature(EStructuralFeature eStructuralFeature)
           
protected  GenOperation findGenOperation(EOperation eOperation)
           
 GenPackage findGenPackage(EPackage ePackage)
           
protected  GenPackage findGenPackageHelper(GenPackage genPackage, EPackage ePackage)
          Finds the GenPackage corresponding to the EPackage, taking into account any nested GenPackages.
 boolean findOrCreateContainer(Monitor progressMonitor, int style, List pluginVariables, URI outputURI, boolean forceStyle)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
 String format(String name, char separator, String prefix, boolean includePrefix)
          Deprecated. in 2.2. Please use format(String, char, String, boolean, boolean) instead.
protected  String format(String name, char separator, String prefix, boolean includePrefix, boolean includeLeadingSeparator)
           
protected  String formatCode(String contents, org.eclipse.jdt.core.formatter.CodeFormatter codeFormatter)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
 void gen(Monitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void gen(Monitor progressMonitor, int style, List pluginVariables, String targetDirectory, String packageName, String className, JETEmitter jetEmitter)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
 void genEdit(Monitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void genEditor(Monitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void generate(IProgressMonitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void generate(Monitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
protected  void generate(Monitor progressMonitor, int style, List pluginVariables, String outputFilePath, GenBaseImpl.GIFEmitter gifEmitter, String key)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  void generate(Monitor progressMonitor, int style, List pluginVariables, String outputFilePath, GenBaseImpl.GIFEmitter gifEmitter, String parentKey, String childKey)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  void generate(Monitor progressMonitor, int style, List pluginVariables, String outputFilePath, JETEmitter jetEmitter)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  void generate(Monitor progressMonitor, int style, List pluginVariables, String targetDirectory, String packageName, String className, JETEmitter jetEmitter)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  void generate(Monitor progressMonitor, int style, List pluginVariables, String targetDirectory, String packageName, String className, JETEmitter jetEmitter, Object[] arguments)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
 void generateEdit(IProgressMonitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void generateEdit(Monitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void generateEditor(IProgressMonitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void generateEditor(Monitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void generateSchema(IProgressMonitor progressMonitor)
          Deprecated. In EMF 2.2, schema generation is properly done via a model exporter. This method will be removed after 2.2.
 void generateSchema(Monitor progressMonitor)
          Deprecated. In EMF 2.2, schema generation is properly done via a model exporter. This method will be removed after 2.2.
 void generateTests(IProgressMonitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void generateTests(Monitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
 void genSchema(Monitor progressMonitor)
          Deprecated. In EMF 2.2, schema generation is properly done via a model exporter. This method will be removed after 2.2.
 void genTests(Monitor progressMonitor)
          Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.
protected  List getAllGenPackages()
           
protected  List getAnnotationInfo(EModelElement eModelElement)
           
protected  List getAnnotationInfo(EModelElement eModelElement, GenBaseImpl.AnnotationFilter annotationFilter)
           
 String getContents(URI uri)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  String getDocumentation()
           
 String getDocumentation(String indentation)
           
 EModelElement getEcoreModelElement()
           
protected  String getEffectiveEObjectType()
           
protected  String getEffectiveFeatureMapWrapperInterface()
           
protected  String getEffectiveListType()
           
protected  String getEffectiveMapType()
           
 String getEncoding(URI uri)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  ExtendedMetaData getExtendedMetaData()
           
 GenAnnotation getGenAnnotation(String source)
           
 EList getGenAnnotations()
           
 GenModel getGenModel()
           
protected  String getImplClassName(String interfaceName)
           
protected  String getImportedEffectiveFeatureMapWrapperClass()
           
protected  String getImportedEffectiveFeatureMapWrapperInternalInterface()
           
protected  String getImportedType(EClassifier eType, boolean primitiveAsObject)
          Returns the primitive or class name for the given EClassifier.
protected  ImportManager getImportManager()
           
protected  Class getInstanceClass(EClassifier eType)
           
protected static Set getJavaLangTypes()
          Deprecated.  
protected static Set getJavaReservedWords()
          Deprecated.  
 String getModelInfo()
           
abstract  String getName()
           
protected  String getPrimitiveDefault(EClassifier eType)
           
protected  String getPrimitiveObjectType(EClassifier eType)
           
protected  String getType(EClassifier eType, boolean primitiveAsObject)
          Returns the primitive or qualified class name for the given EClassifier.
protected  List getTypeGenClasses(EClassifier eType, GenPackage firstGenPackage, List genPackages, int max)
          If eType is an EClass, returns the list of GenClasses representing its non-abstract subclasses, beginning with those from the specified firstGenPackage followed by the others in genPackages, and ordered down the inheritance chains within each package.
 boolean hasDocumentation()
           
protected  boolean hasModelContribution()
           
protected  String indent(String text, String indentation)
           
protected static boolean isBlank(String string)
           
protected  boolean isEffectiveSuppressEMFTypes()
           
protected static boolean isJavaUtilMapEntry(String name)
           
protected  boolean isPrimitiveType(EClassifier eType)
           
 boolean isReadOnly(URI uri)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
protected  List parseName(String sourceName, char sourceSeparator)
          Deprecated. in 2.1.0. Use CodeGenUtil.parseName(String, char) instead.
 void reconcileGenAnnotations(GenBase oldGenBase)
           
 String safeName(String name)
           
protected  void setImportManager(ImportManager importManager)
           
 void setOverwriteable(URI uri)
          Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.
 String uncapName(String name)
           
 String uncapPrefixedName(String name)
           
 String uncapPrefixedName(String name, boolean forceDifferent)
           
protected static String unicodeEscapeEncode(String unicode)
          Deprecated. In EMF 2.2, this moved to CodeGenUtil. This copy will be removed after 2.2.
 
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
eAddVirtualValue, eAllContents, eBaseStructuralFeatureID, eBasicRemoveFromContainer, eBasicRemoveFromContainerFeature, eBasicSetContainer, eComputeVirtualValuesCapacity, eContainer, eContainingFeature, eContainmentFeature, eContainmentFeature, eContains, eContents, eCrossReferences, eDerivedStructuralFeatureID, eDerivedStructuralFeatureID, eDirectResource, eDynamicBasicRemoveFromContainer, eDynamicClass, eDynamicFeature, eDynamicFeatureID, eDynamicGet, eDynamicGet, eDynamicGet, eDynamicInverseAdd, eDynamicInverseAdd, eDynamicInverseRemove, eDynamicInverseRemove, eDynamicIsSet, eDynamicIsSet, eDynamicIsSet, eDynamicSet, eDynamicSet, eDynamicSet, eDynamicUnset, eDynamicUnset, eDynamicUnset, eGet, eGet, eGet, eHasSettings, eInternalResource, eInverseAdd, eInverseRemove, eIsSet, eOpenGet, eOpenIsSet, eOpenSet, eOpenUnset, eProxyURI, eRemoveVirtualValue, eResolveProxy, eResource, eSet, eSetDirectResource, eSetResource, eSetStore, eSetting, eSettingDelegate, eSettings, eSetVirtualIndexBits, eSetVirtualValue, eSetVirtualValues, eStaticFeatureCount, eStore, eUnset, eVirtualBitCount, eVirtualGet, eVirtualGet, eVirtualIndex, eVirtualIndexBits, eVirtualIsSet, eVirtualSet, eVirtualUnset, eVirtualValue, eVirtualValues, toString
 
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.codegen.ecore.genmodel.GenBase
reconcile
 
Methods inherited from interface org.eclipse.emf.ecore.EObject
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eIsProxy, eIsSet, eResource, eSet, eUnset
 
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

genAnnotations

protected EList genAnnotations
The cached value of the 'Gen Annotations' containment reference list.

See Also:
getGenAnnotations()

ecoreGenPackage

protected static GenPackage ecoreGenPackage

xmlTypeGenPackage

protected static GenPackage xmlTypeGenPackage

xmlNamespaceGenPackage

protected static GenPackage xmlNamespaceGenPackage

DEFAULT_ANNOTATION_FILTER

protected static final GenBaseImpl.AnnotationFilter DEFAULT_ANNOTATION_FILTER

PLATFORM_RESOURCE_URI

protected static final URI PLATFORM_RESOURCE_URI
Deprecated. in EMF 2.2


EMPTY_URI

protected static final URI EMPTY_URI
Deprecated. in EMF 2.2

Constructor Detail

GenBaseImpl

protected GenBaseImpl()

Method Detail

eStaticClass

protected EClass eStaticClass()

Overrides:
eStaticClass in class EObjectImpl

getGenAnnotations

public EList getGenAnnotations()

Specified by:
getGenAnnotations in interface GenBase
Returns:
the value of the 'Gen Annotations' containment reference list.
See Also:
GenModelPackage.getGenBase_GenAnnotations(), GenAnnotation.getGenBase()

getGenAnnotation

public GenAnnotation getGenAnnotation(String source)

Specified by:
getGenAnnotation in interface GenBase

eInverseAdd

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

Overrides:
eInverseAdd in class BasicEObjectImpl

eInverseRemove

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

Overrides:
eInverseRemove in class BasicEObjectImpl

eGet

public Object eGet(int featureID,
                   boolean resolve,
                   boolean coreType)

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

eSet

public void eSet(int featureID,
                 Object newValue)

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

eUnset

public void eUnset(int featureID)

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

eIsSet

public boolean eIsSet(int featureID)

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

getGenModel

public GenModel getGenModel()
Specified by:
getGenModel in interface GenBase

getName

public abstract String getName()

capName

public String capName(String name)
Specified by:
capName in interface GenBase

uncapName

public String uncapName(String name)
Specified by:
uncapName in interface GenBase

uncapPrefixedName

public String uncapPrefixedName(String name)
Specified by:
uncapPrefixedName in interface GenBase

uncapPrefixedName

public String uncapPrefixedName(String name,
                                boolean forceDifferent)

safeName

public String safeName(String name)
Specified by:
safeName in interface GenBase

getImplClassName

protected String getImplClassName(String interfaceName)

canGenerate

public boolean canGenerate()
Specified by:
canGenerate in interface GenBase

hasModelContribution

protected boolean hasModelContribution()

generate

public final void generate(IProgressMonitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
generate in interface GenBase

gen

public final void gen(Monitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
gen in interface GenBase

generate

public void generate(Monitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
generate in interface GenBase

generate

protected void generate(Monitor progressMonitor,
                        int style,
                        List pluginVariables,
                        String outputFilePath,
                        JETEmitter jetEmitter)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


createMonitor

protected Monitor createMonitor(Monitor monitor,
                                int ticks)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


generate

protected void generate(Monitor progressMonitor,
                        int style,
                        List pluginVariables,
                        String outputFilePath,
                        GenBaseImpl.GIFEmitter gifEmitter,
                        String key)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


generate

protected void generate(Monitor progressMonitor,
                        int style,
                        List pluginVariables,
                        String outputFilePath,
                        GenBaseImpl.GIFEmitter gifEmitter,
                        String parentKey,
                        String childKey)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


gen

public void gen(Monitor progressMonitor,
                int style,
                List pluginVariables,
                String targetDirectory,
                String packageName,
                String className,
                JETEmitter jetEmitter)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


generate

protected void generate(Monitor progressMonitor,
                        int style,
                        List pluginVariables,
                        String targetDirectory,
                        String packageName,
                        String className,
                        JETEmitter jetEmitter)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


generate

protected void generate(Monitor progressMonitor,
                        int style,
                        List pluginVariables,
                        String targetDirectory,
                        String packageName,
                        String className,
                        JETEmitter jetEmitter,
                        Object[] arguments)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


getImportManager

protected ImportManager getImportManager()

setImportManager

protected void setImportManager(ImportManager importManager)

formatCode

protected String formatCode(String contents,
                            org.eclipse.jdt.core.formatter.CodeFormatter codeFormatter)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


format

public String format(String name,
                     char separator,
                     String prefix,
                     boolean includePrefix)
Deprecated. in 2.2. Please use format(String, char, String, boolean, boolean) instead.

Specified by:
format in interface GenBase

format

protected String format(String name,
                        char separator,
                        String prefix,
                        boolean includePrefix,
                        boolean includeLeadingSeparator)
Since:
2.2.

parseName

protected final List parseName(String sourceName,
                               char sourceSeparator)
Deprecated. in 2.1.0. Use CodeGenUtil.parseName(String, char) instead.

This method was used to break sourceName into words delimited by sourceSeparator and/or mixed-case naming. Now, it simply returns an empty list.


getAllGenPackages

protected List getAllGenPackages()

findGenPackageHelper

protected GenPackage findGenPackageHelper(GenPackage genPackage,
                                          EPackage ePackage)
Finds the GenPackage corresponding to the EPackage, taking into account any nested GenPackages.


findGenPackage

public GenPackage findGenPackage(EPackage ePackage)

findGenClass

protected GenClass findGenClass(EClass eClass)

findGenEnum

protected GenEnum findGenEnum(EEnum eEnum)

findGenDataType

protected GenDataType findGenDataType(EDataType eDataType)

findGenClassifier

protected GenClassifier findGenClassifier(EClassifier eClassifier)

findGenFeature

protected GenFeature findGenFeature(EStructuralFeature eStructuralFeature)

findGenOperation

protected GenOperation findGenOperation(EOperation eOperation)

isEffectiveSuppressEMFTypes

protected boolean isEffectiveSuppressEMFTypes()

getEffectiveMapType

protected String getEffectiveMapType()

getEffectiveListType

protected String getEffectiveListType()

getEffectiveEObjectType

protected String getEffectiveEObjectType()

getEffectiveFeatureMapWrapperInterface

protected String getEffectiveFeatureMapWrapperInterface()

getImportedEffectiveFeatureMapWrapperInternalInterface

protected String getImportedEffectiveFeatureMapWrapperInternalInterface()

getImportedEffectiveFeatureMapWrapperClass

protected String getImportedEffectiveFeatureMapWrapperClass()

getInstanceClass

protected Class getInstanceClass(EClassifier eType)

isPrimitiveType

protected boolean isPrimitiveType(EClassifier eType)

getPrimitiveObjectType

protected String getPrimitiveObjectType(EClassifier eType)

getPrimitiveDefault

protected String getPrimitiveDefault(EClassifier eType)

getType

protected String getType(EClassifier eType,
                         boolean primitiveAsObject)
Returns the primitive or qualified class name for the given EClassifier. If primitiveAsObject is true, wrapper object names will be returned instead of primitive names (e.g. java.lang.Integer instead of int).


getImportedType

protected String getImportedType(EClassifier eType,
                                 boolean primitiveAsObject)
Returns the primitive or class name for the given EClassifier. Class names will be added as imports to the GenModel's ImportManager, and the imported form will be returned. If primitiveAsObject is true, wrapper object names will be returned instead of primitive names (e.g. Integer instead of int).


getTypeGenClasses

protected List getTypeGenClasses(EClassifier eType,
                                 GenPackage firstGenPackage,
                                 List genPackages,
                                 int max)
If eType is an EClass, returns the list of GenClasses representing its non-abstract subclasses, beginning with those from the specified firstGenPackage followed by the others in genPackages, and ordered down the inheritance chains within each package. Stops searching after max GenClasses are found; -1 for no limit. If eType corresponds to an anonymous complex type, only that class itself is returned; otherwise, no such anonymous classes are included.


getJavaReservedWords

protected static Set getJavaReservedWords()
Deprecated.  

Returns a hash of all Java's keywords and textual literals, as of Java 1.4.


getJavaLangTypes

protected static Set getJavaLangTypes()
Deprecated.  


filterGenClasses

protected List filterGenClasses(List genClasses,
                                GenBaseImpl.GenClassFilter filter)
Return all GenClasses in the specified genClasses list that are accepted by filter; all are accepted if filter is null.


collectGenClasses

protected List collectGenClasses(List eClasses,
                                 GenBaseImpl.GenClassFilter filter)
Iterate over the specified eClasses list, finding the GenClass corresponding to each EClass. Return all such GenClasses if filter is null, or those accepted by filter, otherwise.


collectGenFeatures

protected List collectGenFeatures(List genClasses,
                                  List genFeatures,
                                  GenBaseImpl.GenFeatureFilter filter)
Iterate over the lists returned by calling getGenFeatures() on items in the list of genClasses, and then over the list of genFeatures. Return all such GenFeatures if filter is null, or those accepted by filter, otherwise. Either list argument is ignored if it is null.


collectGenOperations

protected List collectGenOperations(List genClasses,
                                    List genOperations,
                                    GenBaseImpl.GenOperationFilter filter)
Iterate over the lists returned by calling getGenOperations() on items in the list of genClasses, and then over the list of genOperations. Return all such GenOperations if filter is null, or those accepted by filter, otherwise. Either list argument is ignored if it is null.


collectGenConstraints

protected List collectGenConstraints(List genClassifiers,
                                     List genConstraints,
                                     GenBaseImpl.GenConstraintFilter filter)
Iterate over the lists returned by calling getGenConstraints() on items in the list of genClassifiers, and then over the list of genConstraints. Return all such constraint if filter is null, or those accepted by filter, otherwise. Either list argument is ignored if it is null.


getModelInfo

public String getModelInfo()

getAnnotationInfo

protected List getAnnotationInfo(EModelElement eModelElement)

getAnnotationInfo

protected List getAnnotationInfo(EModelElement eModelElement,
                                 GenBaseImpl.AnnotationFilter annotationFilter)

appendAnnotationInfo

protected void appendAnnotationInfo(StringBuffer result,
                                    EModelElement eModelElement)

appendAnnotationInfo

protected void appendAnnotationInfo(StringBuffer result,
                                    EModelElement eModelElement,
                                    GenBaseImpl.AnnotationFilter annotationFilter)

appendAnnotationInfo

protected void appendAnnotationInfo(StringBuffer result,
                                    boolean qualified,
                                    EModelElement eModelElement,
                                    GenBaseImpl.AnnotationFilter annotationFilter)

escapeString

protected static String escapeString(String s,
                                     String additionalCharactersToEscape)

appendLineBreak

protected void appendLineBreak(StringBuffer result)

appendModelSetting

protected void appendModelSetting(StringBuffer result,
                                  String qualifier,
                                  String name,
                                  String value)

appendModelSetting

protected void appendModelSetting(StringBuffer result,
                                  String name,
                                  String value)

isJavaUtilMapEntry

protected static boolean isJavaUtilMapEntry(String name)

isBlank

protected static boolean isBlank(String string)

canGenerateEdit

public boolean canGenerateEdit()
Specified by:
canGenerateEdit in interface GenBase

generateEdit

public final void generateEdit(IProgressMonitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
generateEdit in interface GenBase

genEdit

public final void genEdit(Monitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
genEdit in interface GenBase

generateEdit

public void generateEdit(Monitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
generateEdit in interface GenBase

canGenerateEditor

public boolean canGenerateEditor()
Specified by:
canGenerateEditor in interface GenBase

generateEditor

public final void generateEditor(IProgressMonitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
generateEditor in interface GenBase

genEditor

public final void genEditor(Monitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
genEditor in interface GenBase

generateEditor

public void generateEditor(Monitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
generateEditor in interface GenBase

canGenerateSchema

public boolean canGenerateSchema()
Deprecated. In EMF 2.2, schema generation is properly done via a model exporter. This method will be removed after 2.2.

Specified by:
canGenerateSchema in interface GenBase

generateSchema

public final void generateSchema(IProgressMonitor progressMonitor)
Deprecated. In EMF 2.2, schema generation is properly done via a model exporter. This method will be removed after 2.2.

Specified by:
generateSchema in interface GenBase

genSchema

public final void genSchema(Monitor progressMonitor)
Deprecated. In EMF 2.2, schema generation is properly done via a model exporter. This method will be removed after 2.2.

Specified by:
genSchema in interface GenBase

generateSchema

public void generateSchema(Monitor progressMonitor)
Deprecated. In EMF 2.2, schema generation is properly done via a model exporter. This method will be removed after 2.2.

Specified by:
generateSchema in interface GenBase

canGenerateTests

public boolean canGenerateTests()
Specified by:
canGenerateTests in interface GenBase

generateTests

public final void generateTests(IProgressMonitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
generateTests in interface GenBase

genTests

public final void genTests(Monitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
genTests in interface GenBase

generateTests

public void generateTests(Monitor progressMonitor)
Deprecated. In EMF 2.2, a Generator should be used to generate code. This method will be removed after 2.2.

Specified by:
generateTests in interface GenBase

eURIFragmentSegment

public String eURIFragmentSegment(EStructuralFeature eStructuralFeature,
                                  EObject eObject)
Description copied from interface: InternalEObject
Returns the fragment segment that, when passed to eObjectForURIFragmentSegment, will resolve to the given object in this object's given feature.

The feature argument may be null in which case it will be deduced, if possible. The default result will be of the form:

  "@<feature-name>[.<index>]"
The index is used only for many-valued features; it represents the position within the list.

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

eObjectForURIFragmentSegment

public EObject eObjectForURIFragmentSegment(String uriFragmentSegment)
Description copied from interface: InternalEObject
Returns the object resolved by the fragment segment.

The fragment segment encoding will typically be of the form returned by eURIFragmentSegment.

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

unicodeEscapeEncode

protected static String unicodeEscapeEncode(String unicode)
Deprecated. In EMF 2.2, this moved to CodeGenUtil. This copy will be removed after 2.2.


getDocumentation

protected String getDocumentation()

hasDocumentation

public boolean hasDocumentation()
Specified by:
hasDocumentation in interface GenBase

getDocumentation

public String getDocumentation(String indentation)
Specified by:
getDocumentation in interface GenBase

indent

protected String indent(String text,
                        String indentation)

getExtendedMetaData

protected ExtendedMetaData getExtendedMetaData()

addNonDuplicates

protected void addNonDuplicates(Collection target,
                                Collection source,
                                Set noDupSet)

findOrCreateContainer

public boolean findOrCreateContainer(Monitor progressMonitor,
                                     int style,
                                     List pluginVariables,
                                     URI outputURI,
                                     boolean forceStyle)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


exists

public boolean exists(URI uri)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


isReadOnly

public boolean isReadOnly(URI uri)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


createInputStream

public InputStream createInputStream(URI uri)
                              throws Exception
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.

Throws:
Exception

createOutputStream

public OutputStream createOutputStream(URI uri)
                                throws Exception
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.

Throws:
Exception

getContents

public String getContents(URI uri)
                   throws Exception
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.

Throws:
Exception

getEncoding

public String getEncoding(URI uri)
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.


setOverwriteable

public void setOverwriteable(URI uri)
                      throws Exception
Deprecated. In EMF 2.2, a GeneratorAdapter should be used to implement code generation. AbstractGeneratorAdapter provides an equivalent to this method. This method will be removed after 2.2.

Throws:
Exception

getEcoreModelElement

public EModelElement getEcoreModelElement()
Specified by:
getEcoreModelElement in interface GenBase

reconcileGenAnnotations

public void reconcileGenAnnotations(GenBase oldGenBase)

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