Top Fields Constructors Methods
org.antlr.v4.codegen.model

public abstract Class SrcOp

extends OutputModelObject
Class Inheritance
Known Direct Subclasses
org.antlr.v4.codegen.model.Sync, org.antlr.v4.codegen.model.TestSetInline, org.antlr.v4.codegen.model.ThrowRecognitionException, org.antlr.v4.codegen.model.decl.CodeBlock, org.antlr.v4.codegen.model.decl.Decl, org.antlr.v4.codegen.model.AddToLabelList, org.antlr.v4.codegen.model.CaptureNextToken, org.antlr.v4.codegen.model.CaptureNextTokenType, org.antlr.v4.codegen.model.ExceptionClause, org.antlr.v4.codegen.model.RuleElement
Imports
org.antlr.v4.codegen.OutputModelFactory, org.antlr.v4.codegen.model.decl.CodeBlock, org.antlr.v4.tool.ast.GrammarAST

Field Summary

Modifier and TypeField and Description
public CodeBlock
enclosingBlock

All operations know in which block they live: CodeBlock, CodeBlockForAlt Templates might need to know block nesting level or find a specific declaration, etc...

public RuleFunction
public int
uniqueID

Used to create unique var names etc...

Inherited from org.antlr.v4.codegen.model.OutputModelObject:
astfactory

Constructor Summary

AccessConstructor and Description
public
public

Method Summary

Modifier and TypeMethod and Description
public String
getContextName()

Return label alt or return name of rule

public CodeBlockForOuterMostAlt
getOuterMostAltCodeBlock()

Walk upwards in model tree, looking for outer alt's code block

Field Detail

enclosingBlockback to summary
public CodeBlock enclosingBlock

All operations know in which block they live: CodeBlock, CodeBlockForAlt Templates might need to know block nesting level or find a specific declaration, etc...

enclosingRuleRunctionback to summary
public RuleFunction enclosingRuleRunction
uniqueIDback to summary
public int uniqueID

Used to create unique var names etc...

Constructor Detail

SrcOpback to summary
public SrcOp(OutputModelFactory factory)
SrcOpback to summary
public SrcOp(OutputModelFactory factory, GrammarAST ast)

Method Detail

getContextNameback to summary
public String getContextName()

Return label alt or return name of rule

getOuterMostAltCodeBlockback to summary
public CodeBlockForOuterMostAlt getOuterMostAltCodeBlock()

Walk upwards in model tree, looking for outer alt's code block