Package org.drools.drl.parser.lang
Class AbstractDRLParser
java.lang.Object
org.drools.drl.parser.lang.AbstractDRLParser
- All Implemented Interfaces:
DRLParser
- Direct Known Subclasses:
DRL5Parser,DRL6Parser,DRL6StrictParser
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ParserHelperprotected org.antlr.runtime.TokenStreamprotected org.antlr.runtime.RecognizerSharedState -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionEntry point method of a DRL compilation unit compilationUnit := packageStatement? ( statement SEMICOLON? )*protected abstract PackageDescrcompilationUnit(Resource resource) voidvoidprotected abstract LanguageLevelOptionbooleanvoidreportError(Exception ex) voidreportError(org.antlr.runtime.RecognitionException ex)
-
Field Details
-
input
protected org.antlr.runtime.TokenStream input -
state
protected org.antlr.runtime.RecognizerSharedState state -
helper
-
-
Constructor Details
-
AbstractDRLParser
public AbstractDRLParser(org.antlr.runtime.TokenStream input)
-
-
Method Details
-
getHelper
-
hasErrors
public boolean hasErrors() -
getErrors
-
getErrorMessages
- Specified by:
getErrorMessagesin interfaceDRLParser
-
enableEditorInterface
public void enableEditorInterface()- Specified by:
enableEditorInterfacein interfaceDRLParser
-
disableEditorInterface
public void disableEditorInterface()- Specified by:
disableEditorInterfacein interfaceDRLParser
-
getEditorInterface
- Specified by:
getEditorInterfacein interfaceDRLParser
-
reportError
public void reportError(org.antlr.runtime.RecognitionException ex) - Specified by:
reportErrorin interfaceDRLParser
-
reportError
- Specified by:
reportErrorin interfaceDRLParser
-
compilationUnit
Entry point method of a DRL compilation unit compilationUnit := packageStatement? ( statement SEMICOLON? )*- Specified by:
compilationUnitin interfaceDRLParser- Returns:
- a PackageDescr with the content of the whole compilation unit
- Throws:
org.antlr.runtime.RecognitionException
-
compilationUnit
public PackageDescr compilationUnit(Resource resource) throws org.antlr.runtime.RecognitionException - Specified by:
compilationUnitin interfaceDRLParser- Throws:
org.antlr.runtime.RecognitionException
-
compilationUnit
protected abstract PackageDescr compilationUnit(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException - Throws:
org.antlr.runtime.RecognitionException
-
getLanguageLevel
-