|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectch.sahits.codegen.generator.AbstractGenerator
ch.sahits.codegen.generator.JETGateway
ch.sahits.codegen.java.generator.jettemplate.AbstractJETTemplateGenerator
public abstract class AbstractJETTemplateGenerator
This class provides common method to create a JET template file
| Field Summary | |
|---|---|
protected java.io.File |
jetTemplateFile
This file is the handle to the jet-template |
| Constructor Summary | |
|---|---|
AbstractJETTemplateGenerator()
Constructor that passes the call to the super class JETGateway |
|
| Method Summary | |
|---|---|
protected void |
addImport(java.lang.String imp)
Add an import directive to the list |
protected abstract void |
addImports()
// * Add all imports |
protected void |
addJetPluginID2Builder(IConfigurationBuilder builder,
java.lang.String jetTempPath)
Add the jetemplate plugin id to the builder |
protected void |
append(java.lang.String s)
Append a string to the jetemplate |
protected void |
appendLn(java.lang.String line)
Append a string to the jetemplate and add a line break |
void |
cleanup()
Execute the cleanup defined in the super class. |
java.lang.String |
generate(IProgressMonitor monitor)
This generation method creates a jetemplate and then calls onto the generation of the super class |
protected abstract void |
generateTemplate()
Create the template file |
void |
init(IJetGatewayConfiguration config)
Initialize the configuration and generator |
protected void |
writeDirective()
Write the jet directive as the first line of the jetemplate. |
| Methods inherited from class ch.sahits.codegen.generator.JETGateway |
|---|
generate, getJETEmitter, getWorkload, init, isInitialized, setMonitor |
| Methods inherited from class ch.sahits.codegen.generator.AbstractGenerator |
|---|
createIfNull, findOrCreateContainer, getConfig, save, setConfig |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface ch.sahits.codegen.generator.IGenerator |
|---|
getConfig, save |
| Field Detail |
|---|
protected java.io.File jetTemplateFile
| Constructor Detail |
|---|
public AbstractJETTemplateGenerator()
JETGateway
| Method Detail |
|---|
public void init(IJetGatewayConfiguration config)
init in interface IBaseGeneratorinit in class JETGateway
public void cleanup()
throws CoreException
cleanup in interface IGeneratorcleanup in class JETGatewayCoreExceptionJETGateway.cleanup()protected final void addImport(java.lang.String imp)
imp - class or package to be importedprotected final void appendLn(java.lang.String line)
line - contents of the line.protected final void append(java.lang.String s)
s - string to be appendedprotected final void writeDirective()
protected abstract void addImports()
protected abstract void generateTemplate()
public java.lang.String generate(IProgressMonitor monitor)
throws CoreException
generate in class JETGatewaymonitor - the progress monitor to use. May be null.
CoreExceptionch.sahits.codegen.generator.JETGateway#generate(org.eclipse.core.runtime.IProgressMonitor)
protected final void addJetPluginID2Builder(IConfigurationBuilder builder,
java.lang.String jetTempPath)
builder - Configuration builderjetTempPath - template pathe of the jetemplate
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||