|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectkoala.dynamicjava.parser.Parser
This class represents a (interpreted) Java 1.1 language parser
Field Summary | |
Token |
jj_nt
|
boolean |
lookingAhead
|
Token |
token
|
ParserTokenManager |
token_source
|
Constructor Summary | |
Parser(java.io.InputStream stream)
|
|
Parser(ParserTokenManager tm)
|
|
Parser(java.io.Reader stream)
|
Method Summary | |
Expression |
additiveExpression()
Used internally to parse an expression |
void |
additiveExpressionLookahead()
Used internally for lookahead |
Expression |
allocationExpression()
Used internally to parse an expression |
void |
allocationExpressionLookahead()
Used internally for lookahead |
Expression |
andExpression()
Used internally to parse an expression |
void |
andExpressionLookahead()
Used internally for lookahead |
java.util.List |
argumentList()
Used internally to parse an expression |
koala.dynamicjava.parser.Parser.ArgumentsSuffix |
arguments()
Used internally to parse an expression |
void |
argumentsLookahead()
Used internally for lookahead |
ArrayAllocation.TypeDescriptor |
arrayDimsAndInits()
Used internally to parse an expression |
void |
arrayDimsAndInitsLookahead()
Used internally for lookahead |
ArrayInitializer |
arrayInitializer()
Parses an array initializer |
void |
arrayInitializerLookahead()
Used internally for lookahead |
koala.dynamicjava.parser.Parser.ExpressionSuffix |
arrayReference()
Used internally to parse an expression |
void |
assignmentOperatorLookahead()
Used internally for lookahead |
BlockStatement |
block()
Parses a block |
void |
blockLookahead()
Used internally for lookahead |
java.util.List |
blockStatement()
Parses one block statement. |
void |
blockStatementLookahead()
Used internally for lookahead |
BreakStatement |
breakStatement()
Parses a break statement |
void |
breakStatementLookahead()
Used internally for lookahead |
Expression |
castExpression()
Used internally to parse an expression |
void |
castExpressionLookahead()
Used internally for lookahead |
void |
castLookahead()
Used internally for lookahead |
koala.dynamicjava.parser.Parser.ClassBody |
classBody()
Used internally to parse the body of a class |
java.util.List |
classBodyDeclaration()
Parses one declaration in the body of a class. |
void |
classBodyDeclarationLookahead()
Used internally for lookahead |
void |
classBodyLookahead()
Used internally for lookahead |
ClassDeclaration |
classDeclaration()
Parses a class declaration |
void |
classDeclarationLookahead()
Used internally for lookahead |
void |
classDeclarationLookahead2()
Used internally for lookahead |
Expression |
classExpression()
Used internally to parse an expression |
Expression |
conditionalAndExpression()
Used internally to parse an expression |
void |
conditionalAndExpressionLookahead()
Used internally for lookahead |
Expression |
conditionalExpression()
Used internally to parse an expression |
void |
conditionalExpressionLookahead()
Used internally for lookahead |
Expression |
conditionalOrExpression()
Used internally to parse an expression |
void |
conditionalOrExpressionLookahead()
Used internally for lookahead |
ConstructorDeclaration |
constructorDeclaration()
Parses a constructor declaration |
void |
constructorDeclarationLookahead()
Used internally for lookahead |
void |
constructorDeclarationLookahead2()
Used internally for lookahead |
ContinueStatement |
continueStatement()
Parses a continue statement |
void |
continueStatementLookahead()
Used internally for lookahead |
void |
disable_tracing()
|
DoStatement |
doStatement()
Parses a do statement |
void |
doStatementLookahead()
Used internally for lookahead |
koala.dynamicjava.parser.Parser.ExpressionSuffix |
dotAllocationExpression()
Used internally to parse an expression |
koala.dynamicjava.parser.Parser.ExpressionSuffix |
dotIdentifier()
Used internally to parse an expression |
koala.dynamicjava.parser.Parser.ExpressionSuffix |
dotThis()
Used internally to parse an expression |
EmptyStatement |
emptyStatement()
Parses an empty statement |
void |
enable_tracing()
|
Expression |
equalityExpression()
Used internally to parse an expression |
void |
equalityExpressionLookahead()
Used internally for lookahead |
Expression |
exclusiveOrExpression()
Used internally to parse an expression |
void |
exclusiveOrExpressionLookahead()
Used internally for lookahead |
ConstructorInvocation |
explicitConstructorInvocation()
Parses a constructor invocation |
void |
explicitConstructorInvocationLookahead()
Used internally for lookahead |
Expression |
expression()
Parses an expression |
void |
expressionLookahead()
Used internally for lookahead |
Expression |
expressionSuffix(Expression pre)
Used internally to parse an expression |
java.util.List |
fieldDeclaration()
Parses a field declaration. |
void |
fieldDeclarationLookahead()
Used internally for lookahead |
java.util.List |
forInit()
Used internally to parse a 'for' statement |
void |
forInitLookahead()
Used internally for lookahead |
FormalParameter |
formalParameter()
Parses one formal parameter |
void |
formalParameterLookahead()
Used internally for lookahead |
java.util.List |
formalParameters()
Parses formal parameters of the form '(param, param, ...)' |
void |
formalParametersLookahead()
Used internally for lookahead |
ForStatement |
forStatement()
Parses a for statement |
void |
forStatementLookahead()
Used internally for lookahead |
ParseException |
generateParseException()
|
Token |
getNextToken()
|
Token |
getToken(int index)
|
Statement |
ifStatement()
Parses an if statement |
void |
ifStatementLookahead()
Used internally for lookahead |
ImportDeclaration |
importDeclaration()
Parses an import declaration |
Expression |
inclusiveOrExpression()
Used internally to parse an expression |
void |
inclusiveOrExpressionLookahead()
Used internally for lookahead |
Initializer |
initializer()
Parses one initializer |
void |
initializerLookahead()
Used internally for lookahead |
Expression |
instanceOfExpression()
Used internally to parse an expression |
void |
instanceOfExpressionLookahead()
Used internally for lookahead |
InterfaceDeclaration |
interfaceDeclaration()
Parses a interface declaration |
void |
interfaceDeclarationLookahead()
Used internally for lookahead |
void |
interfaceDeclarationLookahead2()
Used internally for lookahead |
java.util.List |
interfaceMemberDeclaration()
Parses one declaration in the body of an interface. |
void |
interfaceMemberDeclarationLookahead()
Used internally for lookahead |
Statement |
labeledStatement()
Parses a labeled statement |
void |
labeledStatementLookahead()
Used internally for lookahead |
Expression |
literal()
Used internally to parse an expression |
void |
literalLookahead()
Used internally for lookahead |
java.util.List |
localVariableDeclaration()
Parses one variable declaration |
void |
localVariableDeclarationLookahead()
Used internally for lookahead |
MethodDeclaration |
methodDeclaration()
Parses a method declaration |
void |
methodDeclarationLookahead()
Used internally for lookahead |
void |
methodDeclarationLookahead2()
Used internally for lookahead |
void |
methodDeclaratorLookahead()
Used internally for lookahead |
koala.dynamicjava.parser.Parser.ModifierFlags |
modifiers()
Used internally to parse a modifier |
void |
modifiersLookahead()
Used internally for lookahead |
Expression |
multiplicativeExpression()
Used internally to parse an expression |
void |
multiplicativeExpressionLookahead()
Used internally for lookahead |
java.util.List |
name()
Parses a name |
java.util.List |
nameList()
Parses a comma separated list of names |
void |
nameListLookahead()
Used internally for lookahead |
void |
nameLookahead()
Used internally for lookahead |
PackageDeclaration |
packageDeclaration()
Parses a package declaration |
java.util.List |
parseCompilationUnit()
Parses a Java compilation unit |
java.util.List |
parseStream()
Parses top level statements. |
Expression |
postfixExpression()
Used internally to parse an expression |
void |
postfixExpressionLookahead()
Used internally for lookahead |
Expression |
preDecrementExpression()
Used internally to parse an expression |
void |
preDecrementExpressionLookahead()
Used internally for lookahead |
Expression |
preIncrementExpression()
Used internally to parse an expression |
void |
preIncrementExpressionLookahead()
Used internally for lookahead |
Expression |
primaryExpression()
Used internally to parse an expression |
void |
primaryExpressionLookahead()
Used internally for lookahead |
Expression |
primaryPrefix()
Used internally to parse an expression |
void |
primaryPrefixLookahead()
Used internally for lookahead |
koala.dynamicjava.parser.Parser.ExpressionSuffix |
primarySuffix()
Used internally to parse an expression |
void |
primarySuffixLookahead()
Used internally for lookahead |
Type |
primitiveType()
Used internally to parse types |
void |
primitiveTypeLookahead()
Used internally for lookahead |
Expression |
qualifiedName()
Used internally to parse an expression |
void |
ReInit(java.io.InputStream stream)
|
void |
ReInit(ParserTokenManager tm)
|
void |
ReInit(java.io.Reader stream)
|
Expression |
relationalExpression()
Used internally to parse an expression |
void |
relationalExpressionLookahead()
Used internally for lookahead |
Type |
resultType()
Used internally to parse types |
void |
resultTypeLookahead()
Used internally for lookahead |
ReturnStatement |
returnStatement()
Parses a return statement |
void |
returnStatementLookahead()
Used internally for lookahead |
void |
setFilename(java.lang.String fname)
Sets the current filename |
Expression |
shiftExpression()
Used internally to parse an expression |
void |
shiftExpressionLookahead()
Used internally for lookahead |
Allocation |
simpleAllocationExpression()
Used internally to parse an expression |
Node |
statement()
Parses one statement |
Node |
statementExpression()
Parses one statement expression |
java.util.List |
statementExpressionList()
Parses a comma separated list of expression |
void |
statementExpressionListLookahead()
Used internally for lookahead |
void |
statementExpressionLookahead()
Used internally for lookahead |
void |
statementLookahead()
Used internally for lookahead |
Expression |
superExpression()
Used internally to parse an expression |
SwitchStatement |
switchStatement()
Parses a switch statement |
void |
switchStatementLookahead()
Used internally for lookahead |
SynchronizedStatement |
synchronizedStatement()
Parses a synchronized statement |
void |
synchronizedStatementLookahead()
Used internally for lookahead |
Expression |
thisExpression()
Used internally to parse an expression |
ThrowStatement |
throwStatement()
Parses a throw statement |
void |
throwStatementLookahead()
Used internally for lookahead |
Node |
topLevelStatement()
Parses one top level statement. |
TryStatement |
tryStatement()
Parses a try statement |
void |
tryStatementLookahead()
Used internally for lookahead |
Type |
type()
Used internally to parse types |
TypeDeclaration |
typeDeclaration()
Parses a type declaration |
void |
typeLookahead()
Used internally for lookahead |
Expression |
unaryExpression()
Used internally to parse an expression |
void |
unaryExpressionLookahead()
Used internally for lookahead |
Expression |
unaryExpressionNotPlusMinus()
Used internally to parse an expression |
void |
unaryExpressionNotPlusMinusLookahead()
Used internally for lookahead |
ClassDeclaration |
unmodifiedClassDeclaration(koala.dynamicjava.parser.Parser.ModifierFlags mf)
Parses a class declaration without modifier |
void |
unmodifiedClassDeclarationLookahead()
Used internally for lookahead |
InterfaceDeclaration |
unmodifiedInterfaceDeclaration(koala.dynamicjava.parser.Parser.ModifierFlags mf)
Parses a interface declaration without modifier |
void |
unmodifiedInterfaceDeclarationLookahead()
Used internally for lookahead |
void |
variableDeclaratorIdLookahead()
Used internally for lookahead |
void |
variableDeclaratorLookahead()
Used internally for lookahead |
Expression |
variableInitializer()
Parses a variable initializer (ie. |
void |
variableInitializerLookahead()
Used internally for lookahead |
WhileStatement |
whileStatement()
Parses a while statement |
void |
whileStatementLookahead()
Used internally for lookahead |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public ParserTokenManager token_source
public Token token
public Token jj_nt
public boolean lookingAhead
Constructor Detail |
public Parser(java.io.InputStream stream)
public Parser(java.io.Reader stream)
public Parser(ParserTokenManager tm)
Method Detail |
public void setFilename(java.lang.String fname)
fname
- the name of the input filepublic final java.util.List parseStream() throws ParseException
ParseException
Node
public final Node topLevelStatement() throws ParseException
ParseException
Node
public final java.util.List parseCompilationUnit() throws ParseException
ParseException
Node
public final PackageDeclaration packageDeclaration() throws ParseException
ParseException
PackageDeclaration
public final ImportDeclaration importDeclaration() throws ParseException
ParseException
ImportDeclaration
public final TypeDeclaration typeDeclaration() throws ParseException
ParseException
TypeDeclaration
public final java.util.List name() throws ParseException
ParseException
TreeToken
public final java.util.List nameList() throws ParseException
ParseException
TreeToken
public final ClassDeclaration classDeclaration() throws ParseException
ParseException
ClassDeclaration
public final koala.dynamicjava.parser.Parser.ModifierFlags modifiers() throws ParseException
ParseException
public final ClassDeclaration unmodifiedClassDeclaration(koala.dynamicjava.parser.Parser.ModifierFlags mf) throws ParseException
ParseException
ClassDeclaration
public final koala.dynamicjava.parser.Parser.ClassBody classBody() throws ParseException
ParseException
public final java.util.List classBodyDeclaration() throws ParseException
ParseException
Node
public final java.util.List fieldDeclaration() throws ParseException
ParseException
FieldDeclaration
public final MethodDeclaration methodDeclaration() throws ParseException
ParseException
MethodDeclaration
public final java.util.List formalParameters() throws ParseException
ParseException
FormalParameter
public final FormalParameter formalParameter() throws ParseException
ParseException
FormalParameter
public final Initializer initializer() throws ParseException
ParseException
Initializer
public final ConstructorDeclaration constructorDeclaration() throws ParseException
ParseException
ConstructorDeclaration
public final ConstructorInvocation explicitConstructorInvocation() throws ParseException
ParseException
ConstructorInvocation
public final InterfaceDeclaration interfaceDeclaration() throws ParseException
ParseException
InterfaceDeclaration
public final InterfaceDeclaration unmodifiedInterfaceDeclaration(koala.dynamicjava.parser.Parser.ModifierFlags mf) throws ParseException
ParseException
InterfaceDeclaration
public final java.util.List interfaceMemberDeclaration() throws ParseException
ParseException
Node
public final ArrayInitializer arrayInitializer() throws ParseException
ParseException
ArrayInitializer
public final Expression variableInitializer() throws ParseException
ParseException
Expression
public final BlockStatement block() throws ParseException
ParseException
BlockStatement
public final java.util.List blockStatement() throws ParseException
ParseException
Node
public final java.util.List localVariableDeclaration() throws ParseException
ParseException
VariableDeclaration
public final Node statement() throws ParseException
ParseException
Node
public final Statement labeledStatement() throws ParseException
ParseException
ContinueTarget
,
LabeledStatement
public final EmptyStatement emptyStatement() throws ParseException
ParseException
EmptyStatement
public final Statement ifStatement() throws ParseException
ParseException
IfThenStatement
,
IfThenElseStatement
public final WhileStatement whileStatement() throws ParseException
ParseException
WhileStatement
public final DoStatement doStatement() throws ParseException
ParseException
DoStatement
public final SwitchStatement switchStatement() throws ParseException
ParseException
SwitchStatement
public final ForStatement forStatement() throws ParseException
ParseException
ForStatement
public final java.util.List forInit() throws ParseException
ParseException
public final java.util.List statementExpressionList() throws ParseException
ParseException
public final BreakStatement breakStatement() throws ParseException
ParseException
BreakStatement
public final ContinueStatement continueStatement() throws ParseException
ParseException
ContinueStatement
public final ReturnStatement returnStatement() throws ParseException
ParseException
ReturnStatement
public final ThrowStatement throwStatement() throws ParseException
ParseException
ThrowStatement
public final SynchronizedStatement synchronizedStatement() throws ParseException
ParseException
SynchronizedStatement
public final TryStatement tryStatement() throws ParseException
ParseException
TryStatement
public final Node statementExpression() throws ParseException
ParseException
Expression
public final Expression expression() throws ParseException
ParseException
Expression
public final Expression expressionSuffix(Expression pre) throws ParseException
ParseException
public final Expression conditionalExpression() throws ParseException
ParseException
public final Expression conditionalOrExpression() throws ParseException
ParseException
public final Expression conditionalAndExpression() throws ParseException
ParseException
public final Expression inclusiveOrExpression() throws ParseException
ParseException
public final Expression exclusiveOrExpression() throws ParseException
ParseException
public final Expression andExpression() throws ParseException
ParseException
public final Expression equalityExpression() throws ParseException
ParseException
public final Expression instanceOfExpression() throws ParseException
ParseException
public final Expression relationalExpression() throws ParseException
ParseException
public final Expression shiftExpression() throws ParseException
ParseException
public final Expression additiveExpression() throws ParseException
ParseException
public final Expression multiplicativeExpression() throws ParseException
ParseException
public final Expression unaryExpression() throws ParseException
ParseException
public final Expression unaryExpressionNotPlusMinus() throws ParseException
ParseException
public final Expression castExpression() throws ParseException
ParseException
public final Expression preIncrementExpression() throws ParseException
ParseException
public final Expression preDecrementExpression() throws ParseException
ParseException
public final Expression postfixExpression() throws ParseException
ParseException
public final Expression primaryExpression() throws ParseException
ParseException
public final Expression primaryPrefix() throws ParseException
ParseException
public final koala.dynamicjava.parser.Parser.ExpressionSuffix primarySuffix() throws ParseException
ParseException
public final koala.dynamicjava.parser.Parser.ExpressionSuffix dotThis() throws ParseException
ParseException
public final koala.dynamicjava.parser.Parser.ExpressionSuffix dotAllocationExpression() throws ParseException
ParseException
public final Allocation simpleAllocationExpression() throws ParseException
ParseException
public final koala.dynamicjava.parser.Parser.ExpressionSuffix dotIdentifier() throws ParseException
ParseException
public final koala.dynamicjava.parser.Parser.ExpressionSuffix arrayReference() throws ParseException
ParseException
public final koala.dynamicjava.parser.Parser.ArgumentsSuffix arguments() throws ParseException
ParseException
public final java.util.List argumentList() throws ParseException
ParseException
public final Expression literal() throws ParseException
ParseException
public final Expression thisExpression() throws ParseException
ParseException
public final Expression superExpression() throws ParseException
ParseException
public final Expression qualifiedName() throws ParseException
ParseException
public final Expression classExpression() throws ParseException
ParseException
public final Expression allocationExpression() throws ParseException
ParseException
public final ArrayAllocation.TypeDescriptor arrayDimsAndInits() throws ParseException
ParseException
public final Type type() throws ParseException
ParseException
public final Type resultType() throws ParseException
ParseException
public final Type primitiveType() throws ParseException
ParseException
public final void castLookahead() throws ParseException
ParseException
public final void typeLookahead() throws ParseException
ParseException
public final void resultTypeLookahead() throws ParseException
ParseException
public final void nameLookahead() throws ParseException
ParseException
public final void primitiveTypeLookahead() throws ParseException
ParseException
public final void literalLookahead() throws ParseException
ParseException
public final void explicitConstructorInvocationLookahead() throws ParseException
ParseException
public final void argumentsLookahead() throws ParseException
ParseException
public final void expressionLookahead() throws ParseException
ParseException
public final void assignmentOperatorLookahead() throws ParseException
ParseException
public final void conditionalExpressionLookahead() throws ParseException
ParseException
public final void conditionalOrExpressionLookahead() throws ParseException
ParseException
public final void conditionalAndExpressionLookahead() throws ParseException
ParseException
public final void inclusiveOrExpressionLookahead() throws ParseException
ParseException
public final void exclusiveOrExpressionLookahead() throws ParseException
ParseException
public final void andExpressionLookahead() throws ParseException
ParseException
public final void equalityExpressionLookahead() throws ParseException
ParseException
public final void instanceOfExpressionLookahead() throws ParseException
ParseException
public final void relationalExpressionLookahead() throws ParseException
ParseException
public final void shiftExpressionLookahead() throws ParseException
ParseException
public final void additiveExpressionLookahead() throws ParseException
ParseException
public final void multiplicativeExpressionLookahead() throws ParseException
ParseException
public final void unaryExpressionLookahead() throws ParseException
ParseException
public final void preIncrementExpressionLookahead() throws ParseException
ParseException
public final void preDecrementExpressionLookahead() throws ParseException
ParseException
public final void unaryExpressionNotPlusMinusLookahead() throws ParseException
ParseException
public final void postfixExpressionLookahead() throws ParseException
ParseException
public final void castExpressionLookahead() throws ParseException
ParseException
public final void primaryExpressionLookahead() throws ParseException
ParseException
public final void primaryPrefixLookahead() throws ParseException
ParseException
public final void primarySuffixLookahead() throws ParseException
ParseException
public final void allocationExpressionLookahead() throws ParseException
ParseException
public final void classBodyLookahead() throws ParseException
ParseException
public final void classBodyDeclarationLookahead() throws ParseException
ParseException
public final void initializerLookahead() throws ParseException
ParseException
public final void modifiersLookahead() throws ParseException
ParseException
public final void constructorDeclarationLookahead() throws ParseException
ParseException
public final void constructorDeclarationLookahead2() throws ParseException
ParseException
public final void methodDeclarationLookahead() throws ParseException
ParseException
public final void methodDeclarationLookahead2() throws ParseException
ParseException
public final void nameListLookahead() throws ParseException
ParseException
public final void methodDeclaratorLookahead() throws ParseException
ParseException
public final void formalParametersLookahead() throws ParseException
ParseException
public final void formalParameterLookahead() throws ParseException
ParseException
public final void fieldDeclarationLookahead() throws ParseException
ParseException
public final void variableDeclaratorLookahead() throws ParseException
ParseException
public final void variableDeclaratorIdLookahead() throws ParseException
ParseException
public final void blockLookahead() throws ParseException
ParseException
public final void blockStatementLookahead() throws ParseException
ParseException
public final void statementLookahead() throws ParseException
ParseException
public final void labeledStatementLookahead() throws ParseException
ParseException
public final void statementExpressionLookahead() throws ParseException
ParseException
public final void switchStatementLookahead() throws ParseException
ParseException
public final void ifStatementLookahead() throws ParseException
ParseException
public final void whileStatementLookahead() throws ParseException
ParseException
public final void doStatementLookahead() throws ParseException
ParseException
public final void forStatementLookahead() throws ParseException
ParseException
public final void forInitLookahead() throws ParseException
ParseException
public final void statementExpressionListLookahead() throws ParseException
ParseException
public final void breakStatementLookahead() throws ParseException
ParseException
public final void continueStatementLookahead() throws ParseException
ParseException
public final void returnStatementLookahead() throws ParseException
ParseException
public final void throwStatementLookahead() throws ParseException
ParseException
public final void synchronizedStatementLookahead() throws ParseException
ParseException
public final void localVariableDeclarationLookahead() throws ParseException
ParseException
public final void tryStatementLookahead() throws ParseException
ParseException
public final void arrayDimsAndInitsLookahead() throws ParseException
ParseException
public final void arrayInitializerLookahead() throws ParseException
ParseException
public final void variableInitializerLookahead() throws ParseException
ParseException
public final void classDeclarationLookahead() throws ParseException
ParseException
public final void classDeclarationLookahead2() throws ParseException
ParseException
public final void unmodifiedClassDeclarationLookahead() throws ParseException
ParseException
public final void interfaceDeclarationLookahead() throws ParseException
ParseException
public final void interfaceDeclarationLookahead2() throws ParseException
ParseException
public final void unmodifiedInterfaceDeclarationLookahead() throws ParseException
ParseException
public final void interfaceMemberDeclarationLookahead() throws ParseException
ParseException
public void ReInit(java.io.InputStream stream)
public void ReInit(java.io.Reader stream)
public void ReInit(ParserTokenManager tm)
public final Token getNextToken()
public final Token getToken(int index)
public final ParseException generateParseException()
public final void enable_tracing()
public final void disable_tracing()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |