|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object marf.nlp.Parsing.GenericLexicalAnalyzer marf.nlp.Parsing.LexicalAnalyzer
public class LexicalAnalyzer
LexicalAnalyzer class encapsulates the functionality required for lexical analysis of a C+- source program. $Id: LexicalAnalyzer.java,v 1.10 2005/06/16 19:58:57 mokhov Exp $
Field Summary |
---|
Fields inherited from class marf.nlp.Parsing.GenericLexicalAnalyzer |
---|
ErrorLogFilename, ErrorsPresent, LexicalErrors, oFileReader, oStreamTokenizer, oToken, OutputFilename, SourceFilename, SymTab, TokenList |
Constructor Summary | |
---|---|
LexicalAnalyzer(SymbolTable pSymTab)
Constructor. |
Method Summary | |
---|---|
java.util.Vector |
getLexicalErrors()
Returns the list of lexical errors. |
static java.lang.String |
getMARFSourceCodeRevision()
Retrieves class' revision. |
Token |
getNextToken()
Core method of the C+- LexicalAnalyzer. |
boolean |
init()
Initialization routine. |
boolean |
serialize(int piOperation)
Load/Save the textual contents of such as Token list and Error list. |
protected int |
validNum(java.lang.String pstrNum)
Validates that an incoming string is a valid number or not. |
Methods inherited from class marf.nlp.Parsing.GenericLexicalAnalyzer |
---|
createToken, getErrorLogFilename, getErrorsPresent, getOutputFilename, getSourceFilename, getSymTab, getTokenList, scan, setErrorLogFilename, setOutputFilename, setSourceFilename |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LexicalAnalyzer(SymbolTable pSymTab)
Method Detail |
---|
public boolean init()
init
in class GenericLexicalAnalyzer
public boolean serialize(int piOperation)
serialize
in class GenericLexicalAnalyzer
public Token getNextToken()
getNextToken
in class GenericLexicalAnalyzer
protected int validNum(java.lang.String pstrNum)
pstrNum
- a string constating valid numerical chars
public java.util.Vector getLexicalErrors()
public static java.lang.String getMARFSourceCodeRevision()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |