|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjaxx.compiler.JAXXEngine
public class JAXXEngine
The engine to compile jaxx files.
The methodrun() launch the compilation of files.
| Field Summary | |
|---|---|
protected java.util.List<JAXXCompilerFile> |
compilingFiles
Files to compile |
protected CompilerConfiguration |
configuration
configuration of the launchor and underlines compilers |
protected JAXXEngineTask |
currentTask
current pass of the engine |
protected java.util.List<java.lang.String> |
errors
Errors detected while running. |
protected JAXXCompilerFile[] |
incomingFiles
original list of files to compile (says the detected modfied files) |
protected JAXXProfile |
profiler
profile attached to the engine (can be null) |
protected JAXXEngineTask[] |
tasks
tasks to launch |
protected java.util.List<java.lang.String> |
warnings
Warnings detected while running. |
| Constructor Summary | |
|---|---|
protected |
JAXXEngine(CompilerConfiguration configuration,
java.io.File base,
java.lang.String... relativePaths)
|
| Method Summary | |
|---|---|
void |
addError(java.lang.String error)
Add an error to the engine. |
void |
addFileToCompile(java.io.File jaxxFile,
java.lang.String jaxxClassName)
Adds a JAXXCompilerFile given the jaxx file and the
corresponding class fully qualified name. |
void |
addFileToCompile(JAXXCompilerFile file)
Adds a file to be compiled. |
void |
addProfileTime(JAXXCompiler compiler,
java.lang.String key)
Add a profile time for the given compiler and key. |
void |
addWarning(java.lang.String warning)
Add a warning to the engine. |
void |
clearReports()
|
boolean |
containsJaxxFileClassName(java.lang.String className)
|
JAXXCompilerFile[] |
getCompiledFiles()
|
CompilerConfiguration |
getConfiguration()
|
CompiledObjectDecorator |
getDecorator(java.lang.Class<?> type)
Obtain the decorator of the given type. |
CompiledObjectDecorator |
getDecorator(java.lang.String name)
Obtain the decorator of the given name. |
java.util.List<java.lang.String> |
getErrors()
|
JAXXCompilerFile[] |
getFilesToCompile()
|
JAXXCompilerFile[] |
getIncomingFiles()
|
JAXXCompiler |
getJAXXCompiler(java.lang.String className)
Obtain the jaxx compiler of the given class name. |
JAXXCompilerFile |
getJAXXCompilerFile(java.lang.String className)
Obtain the jaxx compiler of the given class name. |
JAXXProfile |
getProfiler()
|
SymbolTable |
getSymbolTable(java.lang.String className)
Obtain the symbo table for the given class name. |
JAXXEngineTask[] |
getTasks()
|
java.lang.String |
getVersion()
|
java.util.List<java.lang.String> |
getWarnings()
|
boolean |
isCompileFirstPassTask()
|
boolean |
isVerbose()
|
JAXXCompiler |
newCompiler(JAXXCompilerFile jaxxFile)
Create a new compiler and attach it to the given jaxxFile. |
protected void |
reset()
Resets all state in preparation for a new compilation session. |
int |
run()
Compiled a set of files. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final CompilerConfiguration configuration
protected final JAXXCompilerFile[] incomingFiles
protected final java.util.List<JAXXCompilerFile> compilingFiles
protected final java.util.List<java.lang.String> warnings
protected final java.util.List<java.lang.String> errors
protected JAXXEngineTask[] tasks
protected JAXXEngineTask currentTask
protected JAXXProfile profiler
| Constructor Detail |
|---|
protected JAXXEngine(CompilerConfiguration configuration,
java.io.File base,
java.lang.String... relativePaths)
| Method Detail |
|---|
public JAXXEngineTask[] getTasks()
public java.util.List<java.lang.String> getErrors()
public java.util.List<java.lang.String> getWarnings()
public JAXXProfile getProfiler()
public CompilerConfiguration getConfiguration()
public JAXXCompilerFile[] getIncomingFiles()
public JAXXCompilerFile[] getFilesToCompile()
public JAXXCompilerFile[] getCompiledFiles()
public boolean containsJaxxFileClassName(java.lang.String className)
public boolean isCompileFirstPassTask()
protected void reset()
public void clearReports()
public java.lang.String getVersion()
public JAXXCompilerFile getJAXXCompilerFile(java.lang.String className)
className - the name of the class to use
public JAXXCompiler getJAXXCompiler(java.lang.String className)
className - the name of the class to use
public SymbolTable getSymbolTable(java.lang.String className)
className - the name of the class to use
null if no such symbol table could be found.
public CompiledObjectDecorator getDecorator(java.lang.String name)
throws java.lang.IllegalArgumentException
name - the name of the decorator
java.lang.IllegalArgumentException - if decorator not found for the given name.public CompiledObjectDecorator getDecorator(java.lang.Class<?> type)
type - the type of the decorator (syas his fqn)
public void addWarning(java.lang.String warning)
warning - the warning to addpublic void addError(java.lang.String error)
error - the error to addpublic int run()
-1 if errors appears, the number of generated files
otherwise.public void addFileToCompile(JAXXCompilerFile file)
file to be compiled.
file - the JAXXCompilerFile to add.
public void addFileToCompile(java.io.File jaxxFile,
java.lang.String jaxxClassName)
JAXXCompilerFile given the jaxx file and the
corresponding class fully qualified name.
jaxxFile - the jaxx file locationjaxxClassName - the fully qualified name of the jaxx class
public JAXXCompiler newCompiler(JAXXCompilerFile jaxxFile)
throws java.lang.Exception
jaxxFile.
jaxxFile - the definition of jaxx file to compile
java.lang.Exception - if any pb while creation of compilerpublic boolean isVerbose()
public void addProfileTime(JAXXCompiler compiler,
java.lang.String key)
profiler is null, do nothing
compiler - the compiler to profilekey - the key of profiling
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||