Class CalcCompiler
- All Implemented Interfaces:
org.antlr.v4.runtime.tree.ParseTreeVisitor<gorsat.parser.TypedCalcLambda>,GorScriptVisitor<gorsat.parser.TypedCalcLambda>
public class CalcCompiler extends GorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>
-
Constructor Summary
Constructors Constructor Description CalcCompiler()CalcCompiler(gorsat.parser.ParseArith owner) -
Method Summary
Methods inherited from class org.gorpipe.gor.GorScriptBaseVisitor
visitArgument, visitCalc_command, visitCalc_expression_list, visitColumn_list, visitColumn_name, visitColumn_number, visitColumn_range, visitColumn_ref, visitColumn_rename_rule, visitColumn_selection, visitColumn_wildcard, visitCreate_statement, visitDef_macro, visitFactor, visitFunction_expr, visitFunction_name, visitGeneric_command, visitGor_expression, visitGornor_expression, visitHide_command, visitInput_source, visitMacro_name, visitMacro_value, visitNested_query, visitNor_expression, visitOption, visitOption_value, visitOptional_power_factor, visitOptions_and_args, visitPgor_expression, visitPipe_command, visitPredicate, visitPredicate_factor, visitQuery_expression, visitRename_command, visitReplace_command, visitScript, visitSelect_command, visitString_literal_list, visitValue, visitVirtual_relation, visitVirtual_relation_name, visitWhere_command, visitXfactorMethods inherited from class org.antlr.v4.runtime.tree.AbstractParseTreeVisitor
aggregateResult, defaultResult, shouldVisitNextChild, visit, visitChildren, visitErrorNode, visitTerminal
-
Constructor Details
-
CalcCompiler
public CalcCompiler() -
CalcCompiler
public CalcCompiler(gorsat.parser.ParseArith owner)
-
-
Method Details
-
setColumnNamesAndTypes
public void setColumnNamesAndTypes(java.lang.String[] colNames, java.lang.String[] colTypes) -
addSpecialVars
public void addSpecialVars() -
visitCalc_expression
public gorsat.parser.TypedCalcLambda visitCalc_expression(GorScriptParser.Calc_expressionContext ctx)Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.calc_expression().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitCalc_expressionin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitCalc_expressionin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitExpression
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.expression().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitExpressionin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitExpressionin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitTerm
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.term().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitTermin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitTermin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitSigned_factor
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.signed_factor().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitSigned_factorin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitSigned_factorin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitFunction_call
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.function_call().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitFunction_callin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitFunction_callin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitParen_expr
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.paren_expr().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitParen_exprin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitParen_exprin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitParen_rel_expr
public gorsat.parser.TypedCalcLambda visitParen_rel_expr(GorScriptParser.Paren_rel_exprContext ctx)Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.paren_rel_expr().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitParen_rel_exprin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitParen_rel_exprin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitNot_rel_expr
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.not_rel_expr().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitNot_rel_exprin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitNot_rel_exprin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitIn_expression
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.in_expression().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitIn_expressionin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitIn_expressionin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitIndag_expression
public gorsat.parser.TypedCalcLambda visitIndag_expression(GorScriptParser.Indag_expressionContext ctx)Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.indag_expression().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitIndag_expressionin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitIndag_expressionin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitRel_term
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.rel_term().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitRel_termin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitRel_termin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitRel_expr
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.rel_expr().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitRel_exprin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitRel_exprin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitCompare_expressions
public gorsat.parser.TypedCalcLambda visitCompare_expressions(GorScriptParser.Compare_expressionsContext ctx)Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.compare_expressions().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitCompare_expressionsin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitCompare_expressionsin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitIf_expr
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.if_expr().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitIf_exprin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitIf_exprin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitPower_factor
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.power_factor().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitPower_factorin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitPower_factorin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitString_literal
public gorsat.parser.TypedCalcLambda visitString_literal(GorScriptParser.String_literalContext ctx)Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.string_literal().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitString_literalin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitString_literalin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitNumber
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.number().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitNumberin interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitNumberin classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitVariable
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.variable().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitVariablein interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitVariablein classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitFilename
Description copied from class:GorScriptBaseVisitorVisit a parse tree produced byGorScriptParser.filename().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitFilenamein interfaceGorScriptVisitor<gorsat.parser.TypedCalcLambda>- Overrides:
visitFilenamein classGorScriptBaseVisitor<gorsat.parser.TypedCalcLambda>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-