tip.analysis
Class QuestionAnswerAdapter<Q,A>

java.lang.Object
  extended by tip.analysis.QuestionAnswerAdapter<Q,A>
Type Parameters:
Q - the type of the questions
A - the type of the answers
All Implemented Interfaces:
QuestionAnswer<Q,A>
Direct Known Subclasses:
ConstantPropagationAnalysis.Evaluator, IntervalAnalysis.Evaluator, SignAnalysis.Evaluator

public class QuestionAnswerAdapter<Q,A>
extends Object
implements QuestionAnswer<Q,A>

QuestionAnswerAdapter implements the default behaviour of the QuestionAnswer interface. All calls return null by default.

Author:
Johnni Winther, jw@brics.dk

Constructor Summary
QuestionAnswerAdapter()
           
 
Method Summary
 A caseABinopExp(ABinopExp node, Q question)
          Returns the default answer for a ABinopExp node.
 A caseABlock(ABlock node, Q question)
          Returns the default answer for a ABlock node.
 A caseABlockStm(ABlockStm node, Q question)
          Returns the default answer for a ABlockStm node.
 A caseABody(ABody node, Q question)
          Returns the default answer for a ABody node.
 A caseADeclStm(ADeclStm node, Q question)
          Returns the default answer for a ADeclStm node.
 A caseADerefExp(ADerefExp node, Q question)
          Returns the default answer for a ADerefExp node.
 A caseADivideBinop(ADivideBinop node, Q question)
          Returns the default answer for a ADivideBinop node.
 A caseAEqBinop(AEqBinop node, Q question)
          Returns the default answer for a AEqBinop node.
 A caseAFuncDecl(AFuncDecl node, Q question)
          Returns the default answer for a AFuncDecl node.
 A caseAFunctionCallExp(AFunctionCallExp node, Q question)
          Returns the default answer for a AFunctionCallExp node.
 A caseAFunctionPtrCallExp(AFunctionPtrCallExp node, Q question)
          Returns the default answer for a AFunctionPtrCallExp node.
 A caseAGtBinop(AGtBinop node, Q question)
          Returns the default answer for a AGtBinop node.
 A caseAIfThenElseStm(AIfThenElseStm node, Q question)
          Returns the default answer for a AIfThenElseStm node.
 A caseAIfThenStm(AIfThenStm node, Q question)
          Returns the default answer for a AIfThenStm node.
 A caseAInputExp(AInputExp node, Q question)
          Returns the default answer for a AInputExp node.
 A caseAIntConstExp(AIntConstExp node, Q question)
          Returns the default answer for a AIntConstExp node.
 A caseALocalDecl(ALocalDecl node, Q question)
          Returns the default answer for a ALocalDecl node.
 A caseAMallocExp(AMallocExp node, Q question)
          Returns the default answer for a AMallocExp node.
 A caseAMinusBinop(AMinusBinop node, Q question)
          Returns the default answer for a AMinusBinop node.
 A caseANullExp(ANullExp node, Q question)
          Returns the default answer for a ANullExp node.
 A caseAOutputStm(AOutputStm node, Q question)
          Returns the default answer for a AOutputStm node.
 A caseAPlusBinop(APlusBinop node, Q question)
          Returns the default answer for a APlusBinop node.
 A caseAPointerExp(APointerExp node, Q question)
          Returns the default answer for a APointerExp node.
 A caseAProgram(AProgram node, Q question)
          Returns the default answer for a AProgram node.
 A caseAReturnStm(AReturnStm node, Q question)
          Returns the default answer for a AReturnStm node.
 A caseATimesBinop(ATimesBinop node, Q question)
          Returns the default answer for a ATimesBinop node.
 A caseAVarExp(AVarExp node, Q question)
          Returns the default answer for a AVarExp node.
 A caseAWhileStm(AWhileStm node, Q question)
          Returns the default answer for a AWhileStm node.
 A caseEOF(EOF node, Q question)
          Returns the default answer for a EOF node.
 A caseStart(Start node, Q question)
          Returns the default answer for a Start node.
 A caseTAnd(TAnd node, Q question)
          Returns the default answer for a TAnd node.
 A caseTAssign(TAssign node, Q question)
          Returns the default answer for a TAssign node.
 A caseTComma(TComma node, Q question)
          Returns the default answer for a TComma node.
 A caseTCommentBlock(TCommentBlock node, Q question)
          Returns the default answer for a TCommentBlock node.
 A caseTCommentSingle(TCommentSingle node, Q question)
          Returns the default answer for a TCommentSingle node.
 A caseTDiv(TDiv node, Q question)
          Returns the default answer for a TDiv node.
 A caseTElse(TElse node, Q question)
          Returns the default answer for a TElse node.
 A caseTEq(TEq node, Q question)
          Returns the default answer for a TEq node.
 A caseTGt(TGt node, Q question)
          Returns the default answer for a TGt node.
 A caseTIdentifier(TIdentifier node, Q question)
          Returns the default answer for a TIdentifier node.
 A caseTIf(TIf node, Q question)
          Returns the default answer for a TIf node.
 A caseTInput(TInput node, Q question)
          Returns the default answer for a TInput node.
 A caseTIntegerConst(TIntegerConst node, Q question)
          Returns the default answer for a TIntegerConst node.
 A caseTLBrace(TLBrace node, Q question)
          Returns the default answer for a TLBrace node.
 A caseTLPar(TLPar node, Q question)
          Returns the default answer for a TLPar node.
 A caseTMalloc(TMalloc node, Q question)
          Returns the default answer for a TMalloc node.
 A caseTMinus(TMinus node, Q question)
          Returns the default answer for a TMinus node.
 A caseTNull(TNull node, Q question)
          Returns the default answer for a TNull node.
 A caseTOutput(TOutput node, Q question)
          Returns the default answer for a TOutput node.
 A caseTPlus(TPlus node, Q question)
          Returns the default answer for a TPlus node.
 A caseTRBrace(TRBrace node, Q question)
          Returns the default answer for a TRBrace node.
 A caseTReturn(TReturn node, Q question)
          Returns the default answer for a TReturn node.
 A caseTRPar(TRPar node, Q question)
          Returns the default answer for a TRPar node.
 A caseTSemicolon(TSemicolon node, Q question)
          Returns the default answer for a TSemicolon node.
 A caseTStar(TStar node, Q question)
          Returns the default answer for a TStar node.
 A caseTVar(TVar node, Q question)
          Returns the default answer for a TVar node.
 A caseTWhile(TWhile node, Q question)
          Returns the default answer for a TWhile node.
 A caseTWhiteSpace(TWhiteSpace node, Q question)
          Returns the default answer for a TWhiteSpace node.
 A caseAAssignPtrStm(AAssignPtrStm node, Q question)
          Returns the default answer for a AAssignPtrStm node.
 A caseAAssignVarStm(AAssignVarStm node, Q question)
          Returns the default answer for a AAssignVarStm node.
 A defaultNode(Node node, Q question)
          Returns the default answer for a Node.
 A defaultPBinop(PBinop node, Q question)
          Returns the default answer for a PBinop node.
 A defaultPBlock(PBlock node, Q question)
          Returns the default answer for a PBlock node.
 A defaultPBody(PBody node, Q question)
          Returns the default answer for a PBody node.
 A defaultPDecl(PDecl node, Q question)
          Returns the default answer for a PDecl node.
 A defaultPExp(PExp node, Q question)
          Returns the default answer for a PExp node.
 A defaultPProgram(PProgram node, Q question)
          Returns the default answer for a PProgram node.
 A defaultPStm(PStm node, Q question)
          Returns the default answer for a PStm node.
 A defaultToken(Token token, Q question)
          Returns the default answer for a Token.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QuestionAnswerAdapter

public QuestionAnswerAdapter()
Method Detail

defaultNode

public A defaultNode(Node node,
                     Q question)
Returns the default answer for a Node.

Parameters:
node - the calling Node
question - the question
Returns:
the default answer for a Node

defaultToken

public A defaultToken(Token token,
                      Q question)
Returns the default answer for a Token. The call is deferred to defaultNode(Node,Object).

Parameters:
token - the calling Token
question - the question
Returns:
the default answer for a Token

caseStart

public A caseStart(Start node,
                   Q question)
Returns the default answer for a Start node. The call is deferred to defaultNode(Node,Object).

Specified by:
caseStart in interface QuestionAnswer<Q,A>
Parameters:
node - the calling Start node
question - the question
Returns:
the default answer for a Start node

caseAProgram

public A caseAProgram(AProgram node,
                      Q question)
Returns the default answer for a AProgram node. The call is deferred to defaultPProgram(PProgram,Object).

Specified by:
caseAProgram in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AProgram node
question - the question
Returns:
the default answer for a AProgram node

caseAFuncDecl

public A caseAFuncDecl(AFuncDecl node,
                       Q question)
Returns the default answer for a AFuncDecl node. The call is deferred to defaultPDecl(PDecl,Object).

Specified by:
caseAFuncDecl in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AFuncDecl node
question - the question
Returns:
the default answer for a AFuncDecl node

caseALocalDecl

public A caseALocalDecl(ALocalDecl node,
                        Q question)
Returns the default answer for a ALocalDecl node. The call is deferred to defaultPDecl(PDecl,Object).

Specified by:
caseALocalDecl in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ALocalDecl node
question - the question
Returns:
the default answer for a ALocalDecl node

caseABody

public A caseABody(ABody node,
                   Q question)
Returns the default answer for a ABody node. The call is deferred to defaultPBody(PBody,Object).

Specified by:
caseABody in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ABody node
question - the question
Returns:
the default answer for a ABody node

caseABlock

public A caseABlock(ABlock node,
                    Q question)
Returns the default answer for a ABlock node. The call is deferred to defaultPBlock(PBlock,Object).

Specified by:
caseABlock in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ABlock node
question - the question
Returns:
the default answer for a ABlock node

caseAPlusBinop

public A caseAPlusBinop(APlusBinop node,
                        Q question)
Returns the default answer for a APlusBinop node. The call is deferred to defaultPBinop(PBinop,Object).

Specified by:
caseAPlusBinop in interface QuestionAnswer<Q,A>
Parameters:
node - the calling APlusBinop node
question - the question
Returns:
the default answer for a APlusBinop node

caseAMinusBinop

public A caseAMinusBinop(AMinusBinop node,
                         Q question)
Returns the default answer for a AMinusBinop node. The call is deferred to defaultPBinop(PBinop,Object).

Specified by:
caseAMinusBinop in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AMinusBinop node
question - the question
Returns:
the default answer for a AMinusBinop node

caseATimesBinop

public A caseATimesBinop(ATimesBinop node,
                         Q question)
Returns the default answer for a ATimesBinop node. The call is deferred to defaultPBinop(PBinop,Object).

Specified by:
caseATimesBinop in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ATimesBinop node
question - the question
Returns:
the default answer for a ATimesBinop node

caseADivideBinop

public A caseADivideBinop(ADivideBinop node,
                          Q question)
Returns the default answer for a ADivideBinop node. The call is deferred to defaultPBinop(PBinop,Object).

Specified by:
caseADivideBinop in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ADivideBinop node
question - the question
Returns:
the default answer for a ADivideBinop node

caseAEqBinop

public A caseAEqBinop(AEqBinop node,
                      Q question)
Returns the default answer for a AEqBinop node. The call is deferred to defaultPBinop(PBinop,Object).

Specified by:
caseAEqBinop in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AEqBinop node
question - the question
Returns:
the default answer for a AEqBinop node

caseAGtBinop

public A caseAGtBinop(AGtBinop node,
                      Q question)
Returns the default answer for a AGtBinop node. The call is deferred to defaultPBinop(PBinop,Object).

Specified by:
caseAGtBinop in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AGtBinop node
question - the question
Returns:
the default answer for a AGtBinop node

caseABinopExp

public A caseABinopExp(ABinopExp node,
                       Q question)
Returns the default answer for a ABinopExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseABinopExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ABinopExp node
question - the question
Returns:
the default answer for a ABinopExp node

caseAPointerExp

public A caseAPointerExp(APointerExp node,
                         Q question)
Returns the default answer for a APointerExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseAPointerExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling APointerExp node
question - the question
Returns:
the default answer for a APointerExp node

caseADerefExp

public A caseADerefExp(ADerefExp node,
                       Q question)
Returns the default answer for a ADerefExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseADerefExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ADerefExp node
question - the question
Returns:
the default answer for a ADerefExp node

caseAIntConstExp

public A caseAIntConstExp(AIntConstExp node,
                          Q question)
Returns the default answer for a AIntConstExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseAIntConstExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AIntConstExp node
question - the question
Returns:
the default answer for a AIntConstExp node

caseAFunctionCallExp

public A caseAFunctionCallExp(AFunctionCallExp node,
                              Q question)
Returns the default answer for a AFunctionCallExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseAFunctionCallExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AFunctionCallExp node
question - the question
Returns:
the default answer for a AFunctionCallExp node

caseAFunctionPtrCallExp

public A caseAFunctionPtrCallExp(AFunctionPtrCallExp node,
                                 Q question)
Returns the default answer for a AFunctionPtrCallExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseAFunctionPtrCallExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AFunctionPtrCallExp node
question - the question
Returns:
the default answer for a AFunctionPtrCallExp node

caseAVarExp

public A caseAVarExp(AVarExp node,
                     Q question)
Returns the default answer for a AVarExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseAVarExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AVarExp node
question - the question
Returns:
the default answer for a AVarExp node

caseAInputExp

public A caseAInputExp(AInputExp node,
                       Q question)
Returns the default answer for a AInputExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseAInputExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AInputExp node
question - the question
Returns:
the default answer for a AInputExp node

caseAMallocExp

public A caseAMallocExp(AMallocExp node,
                        Q question)
Returns the default answer for a AMallocExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseAMallocExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AMallocExp node
question - the question
Returns:
the default answer for a AMallocExp node

caseANullExp

public A caseANullExp(ANullExp node,
                      Q question)
Returns the default answer for a ANullExp node. The call is deferred to defaultPExp(PExp,Object).

Specified by:
caseANullExp in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ANullExp node
question - the question
Returns:
the default answer for a ANullExp node

caseAIfThenStm

public A caseAIfThenStm(AIfThenStm node,
                        Q question)
Returns the default answer for a AIfThenStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseAIfThenStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AIfThenStm node
question - the question
Returns:
the default answer for a AIfThenStm node

caseAIfThenElseStm

public A caseAIfThenElseStm(AIfThenElseStm node,
                            Q question)
Returns the default answer for a AIfThenElseStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseAIfThenElseStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AIfThenElseStm node
question - the question
Returns:
the default answer for a AIfThenElseStm node

caseAWhileStm

public A caseAWhileStm(AWhileStm node,
                       Q question)
Returns the default answer for a AWhileStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseAWhileStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AWhileStm node
question - the question
Returns:
the default answer for a AWhileStm node

caseADeclStm

public A caseADeclStm(ADeclStm node,
                      Q question)
Returns the default answer for a ADeclStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseADeclStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ADeclStm node
question - the question
Returns:
the default answer for a ADeclStm node

caseAReturnStm

public A caseAReturnStm(AReturnStm node,
                        Q question)
Returns the default answer for a AReturnStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseAReturnStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AReturnStm node
question - the question
Returns:
the default answer for a AReturnStm node

caseAOutputStm

public A caseAOutputStm(AOutputStm node,
                        Q question)
Returns the default answer for a AOutputStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseAOutputStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AOutputStm node
question - the question
Returns:
the default answer for a AOutputStm node

caseAAssignVarStm

public A caseAAssignVarStm(AAssignVarStm node,
                           Q question)
Returns the default answer for a AAssignVarStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseAAssignVarStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AAssignVarStm node
question - the question
Returns:
the default answer for a AAssignVarStm node

caseAAssignPtrStm

public A caseAAssignPtrStm(AAssignPtrStm node,
                           Q question)
Returns the default answer for a AAssignPtrStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseAAssignPtrStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling AAssignPtrStm node
question - the question
Returns:
the default answer for a AAssignPtrStm node

caseABlockStm

public A caseABlockStm(ABlockStm node,
                       Q question)
Returns the default answer for a ABlockStm node. The call is deferred to defaultPStm(PStm,Object).

Specified by:
caseABlockStm in interface QuestionAnswer<Q,A>
Parameters:
node - the calling ABlockStm node
question - the question
Returns:
the default answer for a ABlockStm node

caseTWhiteSpace

public A caseTWhiteSpace(TWhiteSpace node,
                         Q question)
Returns the default answer for a TWhiteSpace node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTWhiteSpace in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TWhiteSpace node
question - the question
Returns:
the default answer for a TWhiteSpace node

caseTCommentSingle

public A caseTCommentSingle(TCommentSingle node,
                            Q question)
Returns the default answer for a TCommentSingle node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTCommentSingle in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TCommentSingle node
question - the question
Returns:
the default answer for a TCommentSingle node

caseTCommentBlock

public A caseTCommentBlock(TCommentBlock node,
                           Q question)
Returns the default answer for a TCommentBlock node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTCommentBlock in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TCommentBlock node
question - the question
Returns:
the default answer for a TCommentBlock node

caseTVar

public A caseTVar(TVar node,
                  Q question)
Returns the default answer for a TVar node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTVar in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TVar node
question - the question
Returns:
the default answer for a TVar node

caseTInput

public A caseTInput(TInput node,
                    Q question)
Returns the default answer for a TInput node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTInput in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TInput node
question - the question
Returns:
the default answer for a TInput node

caseTOutput

public A caseTOutput(TOutput node,
                     Q question)
Returns the default answer for a TOutput node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTOutput in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TOutput node
question - the question
Returns:
the default answer for a TOutput node

caseTIf

public A caseTIf(TIf node,
                 Q question)
Returns the default answer for a TIf node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTIf in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TIf node
question - the question
Returns:
the default answer for a TIf node

caseTElse

public A caseTElse(TElse node,
                   Q question)
Returns the default answer for a TElse node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTElse in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TElse node
question - the question
Returns:
the default answer for a TElse node

caseTWhile

public A caseTWhile(TWhile node,
                    Q question)
Returns the default answer for a TWhile node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTWhile in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TWhile node
question - the question
Returns:
the default answer for a TWhile node

caseTReturn

public A caseTReturn(TReturn node,
                     Q question)
Returns the default answer for a TReturn node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTReturn in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TReturn node
question - the question
Returns:
the default answer for a TReturn node

caseTMalloc

public A caseTMalloc(TMalloc node,
                     Q question)
Returns the default answer for a TMalloc node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTMalloc in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TMalloc node
question - the question
Returns:
the default answer for a TMalloc node

caseTNull

public A caseTNull(TNull node,
                   Q question)
Returns the default answer for a TNull node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTNull in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TNull node
question - the question
Returns:
the default answer for a TNull node

caseTLPar

public A caseTLPar(TLPar node,
                   Q question)
Returns the default answer for a TLPar node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTLPar in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TLPar node
question - the question
Returns:
the default answer for a TLPar node

caseTRPar

public A caseTRPar(TRPar node,
                   Q question)
Returns the default answer for a TRPar node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTRPar in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TRPar node
question - the question
Returns:
the default answer for a TRPar node

caseTLBrace

public A caseTLBrace(TLBrace node,
                     Q question)
Returns the default answer for a TLBrace node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTLBrace in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TLBrace node
question - the question
Returns:
the default answer for a TLBrace node

caseTRBrace

public A caseTRBrace(TRBrace node,
                     Q question)
Returns the default answer for a TRBrace node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTRBrace in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TRBrace node
question - the question
Returns:
the default answer for a TRBrace node

caseTSemicolon

public A caseTSemicolon(TSemicolon node,
                        Q question)
Returns the default answer for a TSemicolon node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTSemicolon in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TSemicolon node
question - the question
Returns:
the default answer for a TSemicolon node

caseTComma

public A caseTComma(TComma node,
                    Q question)
Returns the default answer for a TComma node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTComma in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TComma node
question - the question
Returns:
the default answer for a TComma node

caseTAssign

public A caseTAssign(TAssign node,
                     Q question)
Returns the default answer for a TAssign node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTAssign in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TAssign node
question - the question
Returns:
the default answer for a TAssign node

caseTPlus

public A caseTPlus(TPlus node,
                   Q question)
Returns the default answer for a TPlus node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTPlus in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TPlus node
question - the question
Returns:
the default answer for a TPlus node

caseTMinus

public A caseTMinus(TMinus node,
                    Q question)
Returns the default answer for a TMinus node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTMinus in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TMinus node
question - the question
Returns:
the default answer for a TMinus node

caseTStar

public A caseTStar(TStar node,
                   Q question)
Returns the default answer for a TStar node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTStar in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TStar node
question - the question
Returns:
the default answer for a TStar node

caseTDiv

public A caseTDiv(TDiv node,
                  Q question)
Returns the default answer for a TDiv node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTDiv in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TDiv node
question - the question
Returns:
the default answer for a TDiv node

caseTAnd

public A caseTAnd(TAnd node,
                  Q question)
Returns the default answer for a TAnd node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTAnd in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TAnd node
question - the question
Returns:
the default answer for a TAnd node

caseTGt

public A caseTGt(TGt node,
                 Q question)
Returns the default answer for a TGt node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTGt in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TGt node
question - the question
Returns:
the default answer for a TGt node

caseTEq

public A caseTEq(TEq node,
                 Q question)
Returns the default answer for a TEq node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTEq in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TEq node
question - the question
Returns:
the default answer for a TEq node

caseTIntegerConst

public A caseTIntegerConst(TIntegerConst node,
                           Q question)
Returns the default answer for a TIntegerConst node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTIntegerConst in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TIntegerConst node
question - the question
Returns:
the default answer for a TIntegerConst node

caseTIdentifier

public A caseTIdentifier(TIdentifier node,
                         Q question)
Returns the default answer for a TIdentifier node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseTIdentifier in interface QuestionAnswer<Q,A>
Parameters:
node - the calling TIdentifier node
question - the question
Returns:
the default answer for a TIdentifier node

defaultPProgram

public A defaultPProgram(PProgram node,
                         Q question)
Returns the default answer for a PProgram node. The call is deferred to defaultNode(Node,Object).

Parameters:
node - the calling PProgram node
question - the question
Returns:
the default answer for a PProgram node

defaultPDecl

public A defaultPDecl(PDecl node,
                      Q question)
Returns the default answer for a PDecl node. The call is deferred to defaultNode(Node,Object).

Parameters:
node - the calling PDecl node
question - the question
Returns:
the default answer for a PDecl node

defaultPBody

public A defaultPBody(PBody node,
                      Q question)
Returns the default answer for a PBody node. The call is deferred to defaultNode(Node,Object).

Parameters:
node - the calling PBody node
question - the question
Returns:
the default answer for a PBody node

defaultPBlock

public A defaultPBlock(PBlock node,
                       Q question)
Returns the default answer for a PBlock node. The call is deferred to defaultNode(Node,Object).

Parameters:
node - the calling PBlock node
question - the question
Returns:
the default answer for a PBlock node

defaultPBinop

public A defaultPBinop(PBinop node,
                       Q question)
Returns the default answer for a PBinop node. The call is deferred to defaultNode(Node,Object).

Parameters:
node - the calling PBinop node
question - the question
Returns:
the default answer for a PBinop node

defaultPExp

public A defaultPExp(PExp node,
                     Q question)
Returns the default answer for a PExp node. The call is deferred to defaultNode(Node,Object).

Parameters:
node - the calling PExp node
question - the question
Returns:
the default answer for a PExp node

defaultPStm

public A defaultPStm(PStm node,
                     Q question)
Returns the default answer for a PStm node. The call is deferred to defaultNode(Node,Object).

Parameters:
node - the calling PStm node
question - the question
Returns:
the default answer for a PStm node

caseEOF

public A caseEOF(EOF node,
                 Q question)
Returns the default answer for a EOF node. The call is deferred to defaultToken(Token,Object).

Specified by:
caseEOF in interface QuestionAnswer<Q,A>
Parameters:
node - the calling EOF node
question - the question
Returns:
the default answer for a EOF node