org.eclipse.ocl.examples.codegen.java
Class JavaCodeGenerator
java.lang.Object
org.eclipse.ocl.examples.codegen.generator.AbstractCodeGenerator
org.eclipse.ocl.examples.codegen.java.JavaCodeGenerator
- All Implemented Interfaces:
- CodeGenerator
- Direct Known Subclasses:
- JUnitCodeGenerator, OCLinEcoreCodeGenerator
public abstract class JavaCodeGenerator
- extends AbstractCodeGenerator
OCL2JavaClass supports generation of the content of a JavaClassFile to
provide the polymorphic implementation of an ExpressionInOCL.
Field Summary |
static java.util.Map<java.lang.Class<?>,java.lang.Class<?>> |
javaPrimitiveClasses
|
static java.util.Map<java.lang.String,java.lang.Class<?>> |
javaPrimitiveNames
|
static java.lang.Class<?>[] |
knownClasses
The known classes that templates may use in unqualified form. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
javaPrimitiveClasses
public static java.util.Map<java.lang.Class<?>,java.lang.Class<?>> javaPrimitiveClasses
javaPrimitiveNames
public static java.util.Map<java.lang.String,java.lang.Class<?>> javaPrimitiveNames
knownClasses
@NonNull
public static final java.lang.Class<?>[] knownClasses
- The known classes that templates may use in unqualified form. The list is
here in a Java form to reduce the impact of refactoring on Acceleo
templates.
JavaCodeGenerator
public JavaCodeGenerator(@NonNull
MetaModelManager metaModelManager)
initPrimitive
public static void initPrimitive(java.lang.Class<?> class1,
java.lang.Class<?> class2)
createBoxingAnalyzer
@NonNull
public BoxingAnalyzer createBoxingAnalyzer()
createCG2JavaPreVisitor
@NonNull
public CG2JavaPreVisitor createCG2JavaPreVisitor()
createDependencyVisitor
public DependencyVisitor createDependencyVisitor()
createDependencyVisitor
public DependencyVisitor createDependencyVisitor(@NonNull
JavaLocalContext localContext)
createFieldingAnalyzer
@NonNull
public FieldingAnalyzer createFieldingAnalyzer()
createGenModelHelper
@NonNull
protected GenModelHelper createGenModelHelper()
- Specified by:
createGenModelHelper
in class AbstractCodeGenerator
createGlobalContext
@NonNull
protected abstract JavaGlobalContext createGlobalContext()
createId2BoxedJavaClassVisitor
@NonNull
protected Id2BoxedJavaClassVisitor createId2BoxedJavaClassVisitor()
createId2EClassVisitor
@NonNull
protected Id2EClassVisitor createId2EClassVisitor()
createId2UnboxedJavaClassVisitor
@NonNull
protected Id2UnboxedJavaClassVisitor createId2UnboxedJavaClassVisitor()
createNameManager
@NonNull
protected NameManager createNameManager()
- Specified by:
createNameManager
in class AbstractCodeGenerator
getConstantsClass
@Nullable
public java.lang.String getConstantsClass()
getEClass
protected org.eclipse.emf.ecore.EClass getEClass(@NonNull
Type type)
getGlobalContext
@NonNull
public JavaGlobalContext getGlobalContext()
getId2BoxedClassVisitor
@NonNull
public Id2BoxedJavaClassVisitor getId2BoxedClassVisitor()
getId2EClassVisitor
@NonNull
public Id2EClassVisitor getId2EClassVisitor()
getId2UnboxedClassVisitor
@NonNull
public Id2UnboxedJavaClassVisitor getId2UnboxedClassVisitor()
getIterationHelper
@Nullable
public Iteration2Java getIterationHelper(@NonNull
Iteration pivotIteration)
getTypeDescriptor
@NonNull
public TypeDescriptor getTypeDescriptor(@NonNull
CGValuedElement cgElement)
getTypeDescriptor
@NonNull
public TypeDescriptor getTypeDescriptor(@NonNull
ElementId elementId,
boolean isBoxed)