grammar

package
v0.0.0-...-ae32867 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 12, 2020 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Overview

Package grammar contains generated Go code produced by ANTLR V4.

Index

Constants

View Source
const (
	PMMPVarLexerT__0    = 1
	PMMPVarLexerT__1    = 2
	PMMPVarLexerMARKER  = 3
	PMMPVarLexerPATHTAG = 4
	PMMPVarLexerTAG     = 5
	PMMPVarLexerDECIMAL = 6
	PMMPVarLexerDOT     = 7
	PMMPVarLexerWS      = 8
)

PMMPVarLexer tokens.

View Source
const (
	PMMPVarParserEOF     = antlr.TokenEOF
	PMMPVarParserT__0    = 1
	PMMPVarParserT__1    = 2
	PMMPVarParserMARKER  = 3
	PMMPVarParserPATHTAG = 4
	PMMPVarParserTAG     = 5
	PMMPVarParserDECIMAL = 6
	PMMPVarParserDOT     = 7
	PMMPVarParserWS      = 8
)

PMMPVarParser tokens.

View Source
const (
	PMMPVarParserRULE_variable  = 0
	PMMPVarParserRULE_tag       = 1
	PMMPVarParserRULE_suffix    = 2
	PMMPVarParserRULE_subscript = 3
)

PMMPVarParser rules.

Variables

This section is empty.

Functions

This section is empty.

Types

type BasePMMPVarListener

type BasePMMPVarListener struct{}

BasePMMPVarListener is a complete listener for a parse tree produced by PMMPVarParser.

func (*BasePMMPVarListener) EnterEveryRule

func (s *BasePMMPVarListener) EnterEveryRule(ctx antlr.ParserRuleContext)

EnterEveryRule is called when any rule is entered.

func (*BasePMMPVarListener) EnterPathtag

func (s *BasePMMPVarListener) EnterPathtag(ctx *PathtagContext)

EnterPathtag is called when production pathtag is entered.

func (*BasePMMPVarListener) EnterSimpletag

func (s *BasePMMPVarListener) EnterSimpletag(ctx *SimpletagContext)

EnterSimpletag is called when production simpletag is entered.

func (*BasePMMPVarListener) EnterSubscript

func (s *BasePMMPVarListener) EnterSubscript(ctx *SubscriptContext)

EnterSubscript is called when production subscript is entered.

func (*BasePMMPVarListener) EnterSuffix

func (s *BasePMMPVarListener) EnterSuffix(ctx *SuffixContext)

EnterSuffix is called when production suffix is entered.

func (*BasePMMPVarListener) EnterVariable

func (s *BasePMMPVarListener) EnterVariable(ctx *VariableContext)

EnterVariable is called when production variable is entered.

func (*BasePMMPVarListener) ExitEveryRule

func (s *BasePMMPVarListener) ExitEveryRule(ctx antlr.ParserRuleContext)

ExitEveryRule is called when any rule is exited.

func (*BasePMMPVarListener) ExitPathtag

func (s *BasePMMPVarListener) ExitPathtag(ctx *PathtagContext)

ExitPathtag is called when production pathtag is exited.

func (*BasePMMPVarListener) ExitSimpletag

func (s *BasePMMPVarListener) ExitSimpletag(ctx *SimpletagContext)

ExitSimpletag is called when production simpletag is exited.

func (*BasePMMPVarListener) ExitSubscript

func (s *BasePMMPVarListener) ExitSubscript(ctx *SubscriptContext)

ExitSubscript is called when production subscript is exited.

func (*BasePMMPVarListener) ExitSuffix

func (s *BasePMMPVarListener) ExitSuffix(ctx *SuffixContext)

ExitSuffix is called when production suffix is exited.

func (*BasePMMPVarListener) ExitVariable

func (s *BasePMMPVarListener) ExitVariable(ctx *VariableContext)

ExitVariable is called when production variable is exited.

func (*BasePMMPVarListener) VisitErrorNode

func (s *BasePMMPVarListener) VisitErrorNode(node antlr.ErrorNode)

VisitErrorNode is called when an error node is visited.

func (*BasePMMPVarListener) VisitTerminal

func (s *BasePMMPVarListener) VisitTerminal(node antlr.TerminalNode)

VisitTerminal is called when a terminal node is visited.

type ISubscriptContext

type ISubscriptContext interface {
	antlr.ParserRuleContext

	// GetParser returns the parser.
	GetParser() antlr.Parser

	// IsSubscriptContext differentiates from other interfaces.
	IsSubscriptContext()
}

ISubscriptContext is an interface to support dynamic dispatch.

type ISuffixContext

type ISuffixContext interface {
	antlr.ParserRuleContext

	// GetParser returns the parser.
	GetParser() antlr.Parser

	// IsSuffixContext differentiates from other interfaces.
	IsSuffixContext()
}

ISuffixContext is an interface to support dynamic dispatch.

type ITagContext

type ITagContext interface {
	antlr.ParserRuleContext

	// GetParser returns the parser.
	GetParser() antlr.Parser

	// IsTagContext differentiates from other interfaces.
	IsTagContext()
}

ITagContext is an interface to support dynamic dispatch.

type IVariableContext

type IVariableContext interface {
	antlr.ParserRuleContext

	// GetParser returns the parser.
	GetParser() antlr.Parser

	// IsVariableContext differentiates from other interfaces.
	IsVariableContext()
}

IVariableContext is an interface to support dynamic dispatch.

type PMMPVarLexer

type PMMPVarLexer struct {
	*antlr.BaseLexer
	// contains filtered or unexported fields
}

func NewPMMPVarLexer

func NewPMMPVarLexer(input antlr.CharStream) *PMMPVarLexer

type PMMPVarListener

type PMMPVarListener interface {
	antlr.ParseTreeListener

	// EnterVariable is called when entering the variable production.
	EnterVariable(c *VariableContext)

	// EnterPathtag is called when entering the pathtag production.
	EnterPathtag(c *PathtagContext)

	// EnterSimpletag is called when entering the simpletag production.
	EnterSimpletag(c *SimpletagContext)

	// EnterSuffix is called when entering the suffix production.
	EnterSuffix(c *SuffixContext)

	// EnterSubscript is called when entering the subscript production.
	EnterSubscript(c *SubscriptContext)

	// ExitVariable is called when exiting the variable production.
	ExitVariable(c *VariableContext)

	// ExitPathtag is called when exiting the pathtag production.
	ExitPathtag(c *PathtagContext)

	// ExitSimpletag is called when exiting the simpletag production.
	ExitSimpletag(c *SimpletagContext)

	// ExitSuffix is called when exiting the suffix production.
	ExitSuffix(c *SuffixContext)

	// ExitSubscript is called when exiting the subscript production.
	ExitSubscript(c *SubscriptContext)
}

PMMPVarListener is a complete listener for a parse tree produced by PMMPVarParser.

type PMMPVarParser

type PMMPVarParser struct {
	*antlr.BaseParser
}

func NewPMMPVarParser

func NewPMMPVarParser(input antlr.TokenStream) *PMMPVarParser

func (*PMMPVarParser) Subscript

func (p *PMMPVarParser) Subscript() (localctx ISubscriptContext)

func (*PMMPVarParser) Suffix

func (p *PMMPVarParser) Suffix() (localctx ISuffixContext)

func (*PMMPVarParser) Tag

func (p *PMMPVarParser) Tag() (localctx ITagContext)

func (*PMMPVarParser) Variable

func (p *PMMPVarParser) Variable() (localctx IVariableContext)

type PathtagContext

type PathtagContext struct {
	*TagContext
}

func NewPathtagContext

func NewPathtagContext(parser antlr.Parser, ctx antlr.ParserRuleContext) *PathtagContext

func (*PathtagContext) EnterRule

func (s *PathtagContext) EnterRule(listener antlr.ParseTreeListener)

func (*PathtagContext) ExitRule

func (s *PathtagContext) ExitRule(listener antlr.ParseTreeListener)

func (*PathtagContext) GetRuleContext

func (s *PathtagContext) GetRuleContext() antlr.RuleContext

func (*PathtagContext) PATHTAG

func (s *PathtagContext) PATHTAG() antlr.TerminalNode

type SimpletagContext

type SimpletagContext struct {
	*TagContext
}

func NewSimpletagContext

func NewSimpletagContext(parser antlr.Parser, ctx antlr.ParserRuleContext) *SimpletagContext

func (*SimpletagContext) EnterRule

func (s *SimpletagContext) EnterRule(listener antlr.ParseTreeListener)

func (*SimpletagContext) ExitRule

func (s *SimpletagContext) ExitRule(listener antlr.ParseTreeListener)

func (*SimpletagContext) GetRuleContext

func (s *SimpletagContext) GetRuleContext() antlr.RuleContext

func (*SimpletagContext) TAG

type SubscriptContext

type SubscriptContext struct {
	*antlr.BaseParserRuleContext
	// contains filtered or unexported fields
}

func NewEmptySubscriptContext

func NewEmptySubscriptContext() *SubscriptContext

func NewSubscriptContext

func NewSubscriptContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *SubscriptContext

func (*SubscriptContext) DECIMAL

func (s *SubscriptContext) DECIMAL() antlr.TerminalNode

func (*SubscriptContext) EnterRule

func (s *SubscriptContext) EnterRule(listener antlr.ParseTreeListener)

func (*SubscriptContext) ExitRule

func (s *SubscriptContext) ExitRule(listener antlr.ParseTreeListener)

func (*SubscriptContext) GetParser

func (s *SubscriptContext) GetParser() antlr.Parser

func (*SubscriptContext) GetRuleContext

func (s *SubscriptContext) GetRuleContext() antlr.RuleContext

func (*SubscriptContext) IsSubscriptContext

func (*SubscriptContext) IsSubscriptContext()

func (*SubscriptContext) ToStringTree

func (s *SubscriptContext) ToStringTree(ruleNames []string, recog antlr.Recognizer) string

type SuffixContext

type SuffixContext struct {
	*antlr.BaseParserRuleContext
	// contains filtered or unexported fields
}

func NewEmptySuffixContext

func NewEmptySuffixContext() *SuffixContext

func NewSuffixContext

func NewSuffixContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *SuffixContext

func (*SuffixContext) DOT

func (s *SuffixContext) DOT() antlr.TerminalNode

func (*SuffixContext) EnterRule

func (s *SuffixContext) EnterRule(listener antlr.ParseTreeListener)

func (*SuffixContext) ExitRule

func (s *SuffixContext) ExitRule(listener antlr.ParseTreeListener)

func (*SuffixContext) GetParser

func (s *SuffixContext) GetParser() antlr.Parser

func (*SuffixContext) GetRuleContext

func (s *SuffixContext) GetRuleContext() antlr.RuleContext

func (*SuffixContext) IsSuffixContext

func (*SuffixContext) IsSuffixContext()

func (*SuffixContext) TAG

func (s *SuffixContext) TAG() antlr.TerminalNode

func (*SuffixContext) ToStringTree

func (s *SuffixContext) ToStringTree(ruleNames []string, recog antlr.Recognizer) string

type TagContext

type TagContext struct {
	*antlr.BaseParserRuleContext
	// contains filtered or unexported fields
}

func NewEmptyTagContext

func NewEmptyTagContext() *TagContext

func NewTagContext

func NewTagContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *TagContext

func (*TagContext) CopyFrom

func (s *TagContext) CopyFrom(ctx *TagContext)

func (*TagContext) GetParser

func (s *TagContext) GetParser() antlr.Parser

func (*TagContext) GetRuleContext

func (s *TagContext) GetRuleContext() antlr.RuleContext

func (*TagContext) IsTagContext

func (*TagContext) IsTagContext()

func (*TagContext) ToStringTree

func (s *TagContext) ToStringTree(ruleNames []string, recog antlr.Recognizer) string

type VariableContext

type VariableContext struct {
	*antlr.BaseParserRuleContext
	// contains filtered or unexported fields
}

func NewEmptyVariableContext

func NewEmptyVariableContext() *VariableContext

func NewVariableContext

func NewVariableContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *VariableContext

func (*VariableContext) AllSubscript

func (s *VariableContext) AllSubscript() []ISubscriptContext

func (*VariableContext) AllSuffix

func (s *VariableContext) AllSuffix() []ISuffixContext

func (*VariableContext) EnterRule

func (s *VariableContext) EnterRule(listener antlr.ParseTreeListener)

func (*VariableContext) ExitRule

func (s *VariableContext) ExitRule(listener antlr.ParseTreeListener)

func (*VariableContext) GetParser

func (s *VariableContext) GetParser() antlr.Parser

func (*VariableContext) GetRuleContext

func (s *VariableContext) GetRuleContext() antlr.RuleContext

func (*VariableContext) IsVariableContext

func (*VariableContext) IsVariableContext()

func (*VariableContext) MARKER

func (s *VariableContext) MARKER() antlr.TerminalNode

func (*VariableContext) Subscript

func (s *VariableContext) Subscript(i int) ISubscriptContext

func (*VariableContext) Suffix

func (s *VariableContext) Suffix(i int) ISuffixContext

func (*VariableContext) Tag

func (s *VariableContext) Tag() ITagContext

func (*VariableContext) ToStringTree

func (s *VariableContext) ToStringTree(ruleNames []string, recog antlr.Recognizer) string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL