org.objectweb.speedo.generation.compiler
Class Compiler

java.lang.Object
  extended byorg.objectweb.speedo.generation.lib.AbstractGeneratorComponent
      extended byorg.objectweb.speedo.generation.compiler.Compiler
All Implemented Interfaces:
GeneratorComponent

public class Compiler
extends AbstractGeneratorComponent

Compiles all generated .java files.

This class is based on Ant that is a Java-based build tool (see http://jakarta.apache.org/ant for more information).

Author:
S.Chassande-Barrioz

Field Summary
protected  Javac compiler
          Ant Task intended to java compilation
static java.lang.String LOGGER_NAME
           
static char separator
          System separator character (e.g '/' under Unix systems)
 
Fields inherited from class org.objectweb.speedo.generation.lib.AbstractGeneratorComponent
debug, logger, scp
 
Constructor Summary
Compiler()
           
 
Method Summary
 boolean init()
          Initializes this Compiler.
 void process()
          Tries to process the compilation internally.
 
Methods inherited from class org.objectweb.speedo.generation.lib.AbstractGeneratorComponent
getLogger, getSpeedoCompilerParameter, setLogger, setSpeedoCompilerParameter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOGGER_NAME

public static final java.lang.String LOGGER_NAME
See Also:
Constant Field Values

separator

public static final char separator
System separator character (e.g '/' under Unix systems)


compiler

protected Javac compiler
Ant Task intended to java compilation

Constructor Detail

Compiler

public Compiler()
Method Detail

init

public boolean init()
Initializes this Compiler.

Specified by:
init in interface GeneratorComponent
Specified by:
init in class AbstractGeneratorComponent

process

public void process()
             throws SpeedoException
Tries to process the compilation internally.

Specified by:
process in interface GeneratorComponent
Specified by:
process in class AbstractGeneratorComponent
Throws:
SpeedoException - if compilation fails