ICompilerDriver Interface
- public interface ICompilerDriver
ICompilerDriver implementations allow different document types to customize their behavior with respect to the
Javelin compiler framework. See individual methods for more information.
-
All Known Implementing Classes
-
DefaultCompilerDriver
public ILanguageBuilder |
-
createBuilder ()
- Allows an IDocument implementation to return an ILanguageBuilder that will be used for construction
of its parse tree.
|
public Class [] |
-
getAvailableFeatures ()
- Allows an IDocument implementation to specify which compiler features should be supported for that document
type.
|
public boolean |
-
isFeatureAvailable (Class featureClass)
- Determines whether the given feature is in the available features
list for this driver.
|
createBuilder() Method
public ILanguageBuilder
createBuilder()
Allows an IDocument implementation to return an ILanguageBuilder that will be used for construction
of its parse tree. For example, JavaCompilerDriver
returns a JavaBuilder
instance,
which is used to build the standard java parse tree.
Returns
- an object implementing the ILangaugeBuilder interface.
getAvailableFeatures() Method
public Class
[] getAvailableFeatures()
Allows an IDocument implementation to specify which compiler features should be supported for that document
type. Features specified by this method may be accessed via
CompilerSvc.get().getFeature
.
Returns
- an array of classes that implement the IFeature
interface.
isFeatureAvailable(Class) Method
public boolean isFeatureAvailable(Class
featureClass)
Determines whether the given feature is in the available features
list for this driver.
Parameters
-
featureClass
- The class object for the feature in question.
Returns
- true if featureClass is an available feature.