|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface ICompiler
Java component (see IJavaComponent compiler extension interface.
This interface is implemented by implementation of components of type com.zfabrik.compiler.
Supported configuration properties:
java.compile.order property on the Java component.
Compiler extensions operate over a build result folder (usually .class files and other binary resources)
that will be JARred at when all compilers have completed. Compilers will be passed a class path in the
form of a class loader. When required, the actual files and folders of the classpath can be retrieved
by casting that class loader to URLClassLoader and invoking URLClassLoader.getURLs().
Compilers are invoked in order of the specified java.compile.order (see IJavaComponent.COMPILE_ORDER). When
declaring a compiler, a compiler.id must be specified that is used to reference
the compiler when specifying the compiler order.
An example compiler component declaration looks like this:
# # it's a compiler # com.zfabrik.component.type=com.zfabrik.java.compiler # # it's feature_x_compiler # compiler.id=feature_x_compiler # # it's implemented here # component.className=com.acme.impl.FeatureXCompiler
| Nested Class Summary | |
|---|---|
static class |
ICompiler.initializer
|
| Field Summary | |
|---|---|
static ICompiler |
ALL
The facade over all compilers. |
static java.lang.String |
COMPILER_ID
The compiler ID must be defined in the compiler component - e.g. |
static java.lang.String |
TYPE
Compilers must define this type |
| Method Summary | |
|---|---|
boolean |
compile(java.lang.String compName,
java.io.File[] src,
java.io.File dest,
java.lang.ClassLoader cl)
A general purpose compiler api using a class loader as class path abstraction. |
void |
init(ICompilerContext context)
Compiler initialization |
| Field Detail |
|---|
static final java.lang.String TYPE
static final java.lang.String COMPILER_ID
java or scala
static final ICompiler ALL
| Method Detail |
|---|
boolean compile(java.lang.String compName,
java.io.File[] src,
java.io.File dest,
java.lang.ClassLoader cl)
compName - the name of the componentsrc - folder containing the source filesdest - destination folder will contain compile resultscl - class loader as class path abstraction
void init(ICompilerContext context)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||