Package com.scriptbasic.syntax
Class BasicSyntaxAnalyzer
java.lang.Object
com.scriptbasic.syntax.BasicSyntaxAnalyzer
- All Implemented Interfaces:
SyntaxAnalyzer
-
Constructor Summary
ConstructorsConstructorDescriptionBasicSyntaxAnalyzer(LexicalAnalyzer lexicalAnalyzer, CommandFactory commandFactory, NestedStructureHouseKeeper nestedStructureHouseKeeper) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCommand(Command command) Add command to the currently build programanalyze()Perform the syntax analysis.static voidconsumeIgnoredLine(LexicalAnalyzer lexicalAnalyzer, String lexString) static booleanlineToIgnore(String lexString) voidsetLexicalElement(LexicalElement lexicalElement)
-
Constructor Details
-
BasicSyntaxAnalyzer
public BasicSyntaxAnalyzer(LexicalAnalyzer lexicalAnalyzer, CommandFactory commandFactory, NestedStructureHouseKeeper nestedStructureHouseKeeper)
-
-
Method Details
-
lineToIgnore
-
getLexicalElement
-
setLexicalElement
-
analyze
Description copied from interface:SyntaxAnalyzerPerform the syntax analysis.- Specified by:
analyzein interfaceSyntaxAnalyzer- Returns:
- return value
- Throws:
AnalysisException- in case of exception
-
addCommand
Description copied from interface:SyntaxAnalyzerAdd command to the currently build program- Specified by:
addCommandin interfaceSyntaxAnalyzer- Parameters:
command- Command to be added to the current program
-
consumeIgnoredLine
public static void consumeIgnoredLine(LexicalAnalyzer lexicalAnalyzer, String lexString) throws AnalysisException - Throws:
AnalysisException
-