Class calculatorBaseVisitor<Result>
This class provides an empty implementation of IcalculatorVisitor<Result>, which can be extended to create a visitor which only needs to handle a subset of the available methods.
Inheritance
Namespace: GCore.Antlr.Grammers.Calculator
Assembly: Calculator.dll
Syntax
public class calculatorBaseVisitor<Result> : AbstractParseTreeVisitor<Result>, IcalculatorVisitor<Result>, IParseTreeVisitor<Result>
Type Parameters
Name | Description |
---|---|
Result | The return type of the visit operation. |
Methods
| Improve this Doc View SourceVisitAtom(calculatorParser.AtomContext)
Visit a parse tree produced by atom().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitAtom(calculatorParser.AtomContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.AtomContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitConstant(calculatorParser.ConstantContext)
Visit a parse tree produced by constant().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitConstant(calculatorParser.ConstantContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.ConstantContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitEquation(calculatorParser.EquationContext)
Visit a parse tree produced by equation().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitEquation(calculatorParser.EquationContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.EquationContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitExpression(calculatorParser.ExpressionContext)
Visit a parse tree produced by expression().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitExpression(calculatorParser.ExpressionContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.ExpressionContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitFunc_(calculatorParser.Func_Context)
Visit a parse tree produced by func_().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitFunc_(calculatorParser.Func_Context context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.Func_Context | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitFuncname(calculatorParser.FuncnameContext)
Visit a parse tree produced by funcname().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitFuncname(calculatorParser.FuncnameContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.FuncnameContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitMultiplyingExpression(calculatorParser.MultiplyingExpressionContext)
Visit a parse tree produced by multiplyingExpression().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitMultiplyingExpression(calculatorParser.MultiplyingExpressionContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.MultiplyingExpressionContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitPowExpression(calculatorParser.PowExpressionContext)
Visit a parse tree produced by powExpression().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitPowExpression(calculatorParser.PowExpressionContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.PowExpressionContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitRelop(calculatorParser.RelopContext)
Visit a parse tree produced by relop().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitRelop(calculatorParser.RelopContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.RelopContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitScientific(calculatorParser.ScientificContext)
Visit a parse tree produced by scientific().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitScientific(calculatorParser.ScientificContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.ScientificContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitSignedAtom(calculatorParser.SignedAtomContext)
Visit a parse tree produced by signedAtom().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitSignedAtom(calculatorParser.SignedAtomContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.SignedAtomContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |
VisitVariable(calculatorParser.VariableContext)
Visit a parse tree produced by variable().
The default implementation returns the result of calling context
.
Declaration
public virtual Result VisitVariable(calculatorParser.VariableContext context)
Parameters
Type | Name | Description |
---|---|---|
calculatorParser.VariableContext | context | The parse tree. |
Returns
Type | Description |
---|---|
Result |