Package org.terrier.utility
Class ClassNameParser<K>
- java.lang.Object
-
- org.terrier.utility.ClassNameParser<K>
-
- All Implemented Interfaces:
ClassNameParserConstants
public class ClassNameParser<K> extends java.lang.Object implements ClassNameParserConstants
-
-
Field Summary
Fields Modifier and Type Field Description Token
jj_nt
Next token.Token
token
Current token.ClassNameParserTokenManager
token_source
Generated Token Manager.-
Fields inherited from interface org.terrier.utility.ClassNameParserConstants
CLOSE_PAREN, COMMA, DEFAULT, EOF, OPEN_PAREN, PARAM_COMMA, PARAM_WORD, PERIOD, tokenImage, WithinBrackets, WORD
-
-
Constructor Summary
Constructors Constructor Description ClassNameParser(java.io.InputStream stream)
Constructor with InputStream.ClassNameParser(java.io.InputStream stream, java.lang.String encoding)
Constructor with InputStream and supplied encodingClassNameParser(java.io.Reader stream)
Constructor.ClassNameParser(java.lang.String r, java.lang.String _defaultPackage, java.lang.Class<K> cls)
ClassNameParser(ClassNameParserTokenManager tm)
Constructor with generated Token Manager.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
disable_tracing()
Disable tracing.void
enable_tracing()
Enable tracing.ParseException
generateParseException()
Generate ParseException.Token
getNextToken()
Get the next Token.Token
getToken(int index)
Get the specific Token.java.util.List<K>
parseAll()
K
parseOne()
void
ReInit(java.io.InputStream stream)
Reinitialise.void
ReInit(java.io.InputStream stream, java.lang.String encoding)
Reinitialise.void
ReInit(java.io.Reader stream)
Reinitialise.void
ReInit(ClassNameParserTokenManager tm)
Reinitialise.
-
-
-
Field Detail
-
token_source
public ClassNameParserTokenManager token_source
Generated Token Manager.
-
token
public Token token
Current token.
-
jj_nt
public Token jj_nt
Next token.
-
-
Constructor Detail
-
ClassNameParser
public ClassNameParser(java.lang.String r, java.lang.String _defaultPackage, java.lang.Class<K> cls)
-
ClassNameParser
public ClassNameParser(java.io.InputStream stream)
Constructor with InputStream.
-
ClassNameParser
public ClassNameParser(java.io.InputStream stream, java.lang.String encoding)
Constructor with InputStream and supplied encoding
-
ClassNameParser
public ClassNameParser(java.io.Reader stream)
Constructor.
-
ClassNameParser
public ClassNameParser(ClassNameParserTokenManager tm)
Constructor with generated Token Manager.
-
-
Method Detail
-
parseOne
public final K parseOne() throws ParseException, java.lang.Exception
- Throws:
ParseException
java.lang.Exception
-
parseAll
public final java.util.List<K> parseAll() throws ParseException, java.lang.Exception
- Throws:
ParseException
java.lang.Exception
-
ReInit
public void ReInit(java.io.InputStream stream)
Reinitialise.
-
ReInit
public void ReInit(java.io.InputStream stream, java.lang.String encoding)
Reinitialise.
-
ReInit
public void ReInit(java.io.Reader stream)
Reinitialise.
-
ReInit
public void ReInit(ClassNameParserTokenManager tm)
Reinitialise.
-
getNextToken
public final Token getNextToken()
Get the next Token.
-
getToken
public final Token getToken(int index)
Get the specific Token.
-
generateParseException
public ParseException generateParseException()
Generate ParseException.
-
enable_tracing
public final void enable_tracing()
Enable tracing.
-
disable_tracing
public final void disable_tracing()
Disable tracing.
-
-