public class DRL6StrictParser extends AbstractDRLParser implements DRLParser
helper, input, state| Constructor and Description |
|---|
DRL6StrictParser(org.antlr.runtime.TokenStream input) |
| Modifier and Type | Method and Description |
|---|---|
AttributeDescr |
attribute(AttributeSupportBuilder<?> as)
attribute :=
salience
| enabled
| ( NO-LOOP
| AUTO-FOCUS
| LOCK-ON-ACTIVE
| REFRACT
| DIRECT
) BOOLEAN?
|
String |
chunk(int leftDelimiter,
int rightDelimiter,
int location)
Matches a chunk started by the leftDelimiter and ended by the rightDelimiter.
|
protected PackageDescr |
compilationUnit(PackageDescrBuilder pkg) |
String |
conditionalExpression()
Matches a conditional expression
|
String |
conditionalOrExpression()
Matches a conditional || expression
|
BaseDescr |
declare(PackageDescrBuilder pkg)
declare := DECLARE
| (ENTRY-POINT) => entryPointDeclaration
| (WINDOW) => windowDeclaration
| (TRAIT) => typeDeclaration (trait)
| (ENUM) => enumDeclaration
| typeDeclaration (class)
END
|
void |
defaultConsequence(RuleDescrBuilder rule)
defaultConsequence := THEN chunk
|
EntryPointDeclarationDescr |
entryPointDeclaration(DeclareDescrBuilder ddb)
entryPointDeclaration := annotation* ENTRY-POINT stringId END
|
EnumDeclarationDescr |
enumDeclaration(DeclareDescrBuilder ddb) |
FunctionDescr |
function(PackageDescrBuilder pkg)
function := FUNCTION type?
|
protected String |
getConsequenceCode(int first) |
protected org.kie.internal.builder.conf.LanguageLevelOption |
getLanguageLevel() |
GlobalDescr |
globalStatement(PackageDescrBuilder pkg)
globalStatement := GLOBAL type ID
|
ImportDescr |
importStatement(PackageDescrBuilder pkg)
importStatement := IMPORT ((FUNCTION|STATIC)?
|
protected BaseDescr |
lhsExists(CEDescrBuilder<?,?> ce,
boolean allowOr)
lhsExists := EXISTS
( (LEFT_PAREN (or_key|and_key))=> lhsOr // prevents '((' for prefixed and/or
| LEFT_PAREN lhsOr RIGHT_PAREN
| lhsPatternBind
)
|
protected BaseDescr |
lhsForall(CEDescrBuilder<?,?> ce)
lhsForall := FORALL LEFT_PAREN lhsPatternBind+ RIGHT_PAREN
|
protected BaseDescr |
lhsNot(CEDescrBuilder<?,?> ce,
boolean allowOr)
lhsNot := NOT
( (LEFT_PAREN (or_key|and_key))=> lhsOr // prevents '((' for prefixed and/or
| LEFT_PAREN lhsOr RIGHT_PAREN
| lhsPatternBind
)
|
boolean |
mismatchIsMissingToken(org.antlr.runtime.TokenStream input,
int[] follow) |
boolean |
mismatchIsUnwantedToken(org.antlr.runtime.TokenStream input,
int ttype,
String text) |
void |
namedConsequence(RuleDescrBuilder rule)
namedConsequence := THEN LEFT_SQUARE ID RIGHT_SQUARE chunk
|
String |
packageStatement(PackageDescrBuilder pkg)
Parses a package statement and returns the name of the package
or null if none is defined.
|
String |
qualifiedIdentifier()
Matches a qualified identifier
qualifiedIdentifier := ID ( DOT ID )*
|
RuleDescr |
query(PackageDescrBuilder pkg)
query := annotation* QUERY stringId parameters?
|
protected org.antlr.runtime.Token |
recoverFromMismatchedToken(org.antlr.runtime.TokenStream input,
int ttype,
String text,
int[] follow)
Attempt to recover from a single missing or extra token.
|
RuleDescr |
rule(PackageDescrBuilder pkg)
rule := annotation* RULE stringId (EXTENDS stringId)?
|
BaseDescr |
statement(PackageDescrBuilder pkg)
statement := importStatement
| globalStatement
| declare
| rule
| ruleAttribute
| function
| query
;
|
String |
type()
Matches a type name
type := ID typeArguments?
|
String |
typeArgument()
Matches a type argument
typeArguments := QUESTION (( EXTENDS | SUPER ) type )?
|
String |
typeArguments()
Matches type arguments
typeArguments := LESS typeArgument (COMMA typeArgument)* GREATER
|
TypeDeclarationDescr |
typeDeclaration(DeclareDescrBuilder ddb,
boolean isTrait)
typeDeclaration := annotation* [TYPE] qualifiedIdentifier (EXTENDS qualifiedIdentifier)?
|
UnitDescr |
unitStatement(PackageDescrBuilder pkg)
unitStatement := UNIT qualifiedIdentifier SEMICOLON?
|
WindowDeclarationDescr |
windowDeclaration(DeclareDescrBuilder ddb)
windowDeclaration := annotation* WINDOW ID lhsPatternBind END
|
compilationUnit, compilationUnit, disableEditorInterface, enableEditorInterface, getEditorInterface, getErrorMessages, getErrors, getHelper, hasErrors, reportError, reportErrorclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcompilationUnit, compilationUnit, disableEditorInterface, enableEditorInterface, getEditorInterface, getErrorMessages, getErrors, hasErrors, reportError, reportErrorprotected org.kie.internal.builder.conf.LanguageLevelOption getLanguageLevel()
getLanguageLevel in class AbstractDRLParserprotected final PackageDescr compilationUnit(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
compilationUnit in class AbstractDRLParserorg.antlr.runtime.RecognitionExceptionpublic String packageStatement(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic UnitDescr unitStatement(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic BaseDescr statement(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic ImportDescr importStatement(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic GlobalDescr globalStatement(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic BaseDescr declare(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic EntryPointDeclarationDescr entryPointDeclaration(DeclareDescrBuilder ddb) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic WindowDeclarationDescr windowDeclaration(DeclareDescrBuilder ddb) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic EnumDeclarationDescr enumDeclaration(DeclareDescrBuilder ddb) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic TypeDeclarationDescr typeDeclaration(DeclareDescrBuilder ddb, boolean isTrait) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic FunctionDescr function(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic RuleDescr query(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic RuleDescr rule(PackageDescrBuilder pkg) throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic AttributeDescr attribute(AttributeSupportBuilder<?> as)
protected BaseDescr lhsExists(CEDescrBuilder<?,?> ce, boolean allowOr) throws org.antlr.runtime.RecognitionException
ce - org.antlr.runtime.RecognitionExceptionprotected BaseDescr lhsNot(CEDescrBuilder<?,?> ce, boolean allowOr) throws org.antlr.runtime.RecognitionException
ce - org.antlr.runtime.RecognitionExceptionprotected BaseDescr lhsForall(CEDescrBuilder<?,?> ce) throws org.antlr.runtime.RecognitionException
ce - org.antlr.runtime.RecognitionExceptionpublic void defaultConsequence(RuleDescrBuilder rule)
rule - public void namedConsequence(RuleDescrBuilder rule)
rule - protected String getConsequenceCode(int first)
public String type() throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic String typeArguments() throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic String typeArgument() throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic String qualifiedIdentifier() throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic String conditionalExpression() throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic String conditionalOrExpression() throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic String chunk(int leftDelimiter, int rightDelimiter, int location)
protected org.antlr.runtime.Token recoverFromMismatchedToken(org.antlr.runtime.TokenStream input,
int ttype,
String text,
int[] follow)
throws org.antlr.runtime.RecognitionException
org.antlr.runtime.RecognitionExceptionpublic boolean mismatchIsUnwantedToken(org.antlr.runtime.TokenStream input,
int ttype,
String text)
public boolean mismatchIsMissingToken(org.antlr.runtime.TokenStream input,
int[] follow)
Copyright © 2001–2018 JBoss by Red Hat. All rights reserved.