parser

package
Version: v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CCIILexerT__0   = 1
	CCIILexerT__1   = 2
	CCIILexerT__2   = 3
	CCIILexerT__3   = 4
	CCIILexerT__4   = 5
	CCIILexerT__5   = 6
	CCIILexerSCALAR = 7
)

CCIILexer tokens.

View Source
const (
	CCIIParserEOF    = antlr.TokenEOF
	CCIIParserT__0   = 1
	CCIIParserT__1   = 2
	CCIIParserT__2   = 3
	CCIIParserT__3   = 4
	CCIIParserT__4   = 5
	CCIIParserT__5   = 6
	CCIIParserSCALAR = 7
)

CCIIParser tokens.

View Source
const (
	CCIIParserRULE_main          = 0
	CCIIParserRULE_object        = 1
	CCIIParserRULE_object_item   = 2
	CCIIParserRULE_object_intern = 3
	CCIIParserRULE_array         = 4
	CCIIParserRULE_array_item    = 5
	CCIIParserRULE_array_intern  = 6
)

CCIIParser rules.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArrayContext

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

func NewArrayContext

func NewArrayContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *ArrayContext

func NewEmptyArrayContext

func NewEmptyArrayContext() *ArrayContext

func (*ArrayContext) Accept

func (s *ArrayContext) Accept(visitor antlr.ParseTreeVisitor) interface{}

func (*ArrayContext) Array_intern

func (s *ArrayContext) Array_intern() IArray_internContext

func (*ArrayContext) EnterRule

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

func (*ArrayContext) ExitRule

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

func (*ArrayContext) GetParser

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

func (*ArrayContext) GetRuleContext

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

func (*ArrayContext) IsArrayContext

func (*ArrayContext) IsArrayContext()

func (*ArrayContext) ToStringTree

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

type Array_internContext

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

func NewArray_internContext

func NewArray_internContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *Array_internContext

func NewEmptyArray_internContext

func NewEmptyArray_internContext() *Array_internContext

func (*Array_internContext) Accept

func (s *Array_internContext) Accept(visitor antlr.ParseTreeVisitor) interface{}

func (*Array_internContext) AllArray_item

func (s *Array_internContext) AllArray_item() []IArray_itemContext

func (*Array_internContext) Array_item

func (s *Array_internContext) Array_item(i int) IArray_itemContext

func (*Array_internContext) EnterRule

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

func (*Array_internContext) ExitRule

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

func (*Array_internContext) GetParser

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

func (*Array_internContext) GetRuleContext

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

func (*Array_internContext) IsArray_internContext

func (*Array_internContext) IsArray_internContext()

func (*Array_internContext) ToStringTree

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

type Array_itemContext

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

func NewArray_itemContext

func NewArray_itemContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *Array_itemContext

func NewEmptyArray_itemContext

func NewEmptyArray_itemContext() *Array_itemContext

func (*Array_itemContext) Accept

func (s *Array_itemContext) Accept(visitor antlr.ParseTreeVisitor) interface{}

func (*Array_itemContext) Array

func (s *Array_itemContext) Array() IArrayContext

func (*Array_itemContext) EnterRule

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

func (*Array_itemContext) ExitRule

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

func (*Array_itemContext) GetParser

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

func (*Array_itemContext) GetRuleContext

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

func (*Array_itemContext) IsArray_itemContext

func (*Array_itemContext) IsArray_itemContext()

func (*Array_itemContext) Object

func (s *Array_itemContext) Object() IObjectContext

func (*Array_itemContext) SCALAR

func (s *Array_itemContext) SCALAR() antlr.TerminalNode

func (*Array_itemContext) ToStringTree

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

type BaseCCIIListener

type BaseCCIIListener struct{}

BaseCCIIListener is a complete listener for a parse tree produced by CCIIParser.

func (*BaseCCIIListener) EnterArray

func (s *BaseCCIIListener) EnterArray(ctx *ArrayContext)

EnterArray is called when production array is entered.

func (*BaseCCIIListener) EnterArray_intern

func (s *BaseCCIIListener) EnterArray_intern(ctx *Array_internContext)

EnterArray_intern is called when production array_intern is entered.

func (*BaseCCIIListener) EnterArray_item

func (s *BaseCCIIListener) EnterArray_item(ctx *Array_itemContext)

EnterArray_item is called when production array_item is entered.

func (*BaseCCIIListener) EnterEveryRule

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

EnterEveryRule is called when any rule is entered.

func (*BaseCCIIListener) EnterMain

func (s *BaseCCIIListener) EnterMain(ctx *MainContext)

EnterMain is called when production main is entered.

func (*BaseCCIIListener) EnterObject

func (s *BaseCCIIListener) EnterObject(ctx *ObjectContext)

EnterObject is called when production object is entered.

func (*BaseCCIIListener) EnterObject_intern

func (s *BaseCCIIListener) EnterObject_intern(ctx *Object_internContext)

EnterObject_intern is called when production object_intern is entered.

func (*BaseCCIIListener) EnterObject_item

func (s *BaseCCIIListener) EnterObject_item(ctx *Object_itemContext)

EnterObject_item is called when production object_item is entered.

func (*BaseCCIIListener) ExitArray

func (s *BaseCCIIListener) ExitArray(ctx *ArrayContext)

ExitArray is called when production array is exited.

func (*BaseCCIIListener) ExitArray_intern

func (s *BaseCCIIListener) ExitArray_intern(ctx *Array_internContext)

ExitArray_intern is called when production array_intern is exited.

func (*BaseCCIIListener) ExitArray_item

func (s *BaseCCIIListener) ExitArray_item(ctx *Array_itemContext)

ExitArray_item is called when production array_item is exited.

func (*BaseCCIIListener) ExitEveryRule

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

ExitEveryRule is called when any rule is exited.

func (*BaseCCIIListener) ExitMain

func (s *BaseCCIIListener) ExitMain(ctx *MainContext)

ExitMain is called when production main is exited.

func (*BaseCCIIListener) ExitObject

func (s *BaseCCIIListener) ExitObject(ctx *ObjectContext)

ExitObject is called when production object is exited.

func (*BaseCCIIListener) ExitObject_intern

func (s *BaseCCIIListener) ExitObject_intern(ctx *Object_internContext)

ExitObject_intern is called when production object_intern is exited.

func (*BaseCCIIListener) ExitObject_item

func (s *BaseCCIIListener) ExitObject_item(ctx *Object_itemContext)

ExitObject_item is called when production object_item is exited.

func (*BaseCCIIListener) VisitErrorNode

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

VisitErrorNode is called when an error node is visited.

func (*BaseCCIIListener) VisitTerminal

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

VisitTerminal is called when a terminal node is visited.

type BaseCCIIVisitor

type BaseCCIIVisitor struct {
	*antlr.BaseParseTreeVisitor
}

func (*BaseCCIIVisitor) VisitArray

func (v *BaseCCIIVisitor) VisitArray(ctx *ArrayContext) interface{}

func (*BaseCCIIVisitor) VisitArray_intern

func (v *BaseCCIIVisitor) VisitArray_intern(ctx *Array_internContext) interface{}

func (*BaseCCIIVisitor) VisitArray_item

func (v *BaseCCIIVisitor) VisitArray_item(ctx *Array_itemContext) interface{}

func (*BaseCCIIVisitor) VisitMain

func (v *BaseCCIIVisitor) VisitMain(ctx *MainContext) interface{}

func (*BaseCCIIVisitor) VisitObject

func (v *BaseCCIIVisitor) VisitObject(ctx *ObjectContext) interface{}

func (*BaseCCIIVisitor) VisitObject_intern

func (v *BaseCCIIVisitor) VisitObject_intern(ctx *Object_internContext) interface{}

func (*BaseCCIIVisitor) VisitObject_item

func (v *BaseCCIIVisitor) VisitObject_item(ctx *Object_itemContext) interface{}

type CCIILexer

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

func NewCCIILexer

func NewCCIILexer(input antlr.CharStream) *CCIILexer

type CCIIListener

type CCIIListener interface {
	antlr.ParseTreeListener

	// EnterMain is called when entering the main production.
	EnterMain(c *MainContext)

	// EnterObject is called when entering the object production.
	EnterObject(c *ObjectContext)

	// EnterObject_item is called when entering the object_item production.
	EnterObject_item(c *Object_itemContext)

	// EnterObject_intern is called when entering the object_intern production.
	EnterObject_intern(c *Object_internContext)

	// EnterArray is called when entering the array production.
	EnterArray(c *ArrayContext)

	// EnterArray_item is called when entering the array_item production.
	EnterArray_item(c *Array_itemContext)

	// EnterArray_intern is called when entering the array_intern production.
	EnterArray_intern(c *Array_internContext)

	// ExitMain is called when exiting the main production.
	ExitMain(c *MainContext)

	// ExitObject is called when exiting the object production.
	ExitObject(c *ObjectContext)

	// ExitObject_item is called when exiting the object_item production.
	ExitObject_item(c *Object_itemContext)

	// ExitObject_intern is called when exiting the object_intern production.
	ExitObject_intern(c *Object_internContext)

	// ExitArray is called when exiting the array production.
	ExitArray(c *ArrayContext)

	// ExitArray_item is called when exiting the array_item production.
	ExitArray_item(c *Array_itemContext)

	// ExitArray_intern is called when exiting the array_intern production.
	ExitArray_intern(c *Array_internContext)
}

CCIIListener is a complete listener for a parse tree produced by CCIIParser.

type CCIIParser

type CCIIParser struct {
	*antlr.BaseParser
}

func NewCCIIParser

func NewCCIIParser(input antlr.TokenStream) *CCIIParser

func (*CCIIParser) Array

func (p *CCIIParser) Array() (localctx IArrayContext)

func (*CCIIParser) Array_intern

func (p *CCIIParser) Array_intern() (localctx IArray_internContext)

func (*CCIIParser) Array_item

func (p *CCIIParser) Array_item() (localctx IArray_itemContext)

func (*CCIIParser) Main

func (p *CCIIParser) Main() (localctx IMainContext)

func (*CCIIParser) Object

func (p *CCIIParser) Object() (localctx IObjectContext)

func (*CCIIParser) Object_intern

func (p *CCIIParser) Object_intern() (localctx IObject_internContext)

func (*CCIIParser) Object_item

func (p *CCIIParser) Object_item() (localctx IObject_itemContext)

type CCIIVisitor

type CCIIVisitor interface {
	antlr.ParseTreeVisitor

	// Visit a parse tree produced by CCIIParser#main.
	VisitMain(ctx *MainContext) interface{}

	// Visit a parse tree produced by CCIIParser#object.
	VisitObject(ctx *ObjectContext) interface{}

	// Visit a parse tree produced by CCIIParser#object_item.
	VisitObject_item(ctx *Object_itemContext) interface{}

	// Visit a parse tree produced by CCIIParser#object_intern.
	VisitObject_intern(ctx *Object_internContext) interface{}

	// Visit a parse tree produced by CCIIParser#array.
	VisitArray(ctx *ArrayContext) interface{}

	// Visit a parse tree produced by CCIIParser#array_item.
	VisitArray_item(ctx *Array_itemContext) interface{}

	// Visit a parse tree produced by CCIIParser#array_intern.
	VisitArray_intern(ctx *Array_internContext) interface{}
}

A complete Visitor for a parse tree produced by CCIIParser.

type IArrayContext

type IArrayContext interface {
	antlr.ParserRuleContext

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

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

IArrayContext is an interface to support dynamic dispatch.

type IArray_internContext

type IArray_internContext interface {
	antlr.ParserRuleContext

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

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

IArray_internContext is an interface to support dynamic dispatch.

type IArray_itemContext

type IArray_itemContext interface {
	antlr.ParserRuleContext

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

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

IArray_itemContext is an interface to support dynamic dispatch.

type IMainContext

type IMainContext interface {
	antlr.ParserRuleContext

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

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

IMainContext is an interface to support dynamic dispatch.

type IObjectContext

type IObjectContext interface {
	antlr.ParserRuleContext

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

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

IObjectContext is an interface to support dynamic dispatch.

type IObject_internContext

type IObject_internContext interface {
	antlr.ParserRuleContext

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

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

IObject_internContext is an interface to support dynamic dispatch.

type IObject_itemContext

type IObject_itemContext interface {
	antlr.ParserRuleContext

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

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

IObject_itemContext is an interface to support dynamic dispatch.

type MainContext

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

func NewEmptyMainContext

func NewEmptyMainContext() *MainContext

func NewMainContext

func NewMainContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *MainContext

func (*MainContext) Accept

func (s *MainContext) Accept(visitor antlr.ParseTreeVisitor) interface{}

func (*MainContext) Array

func (s *MainContext) Array() IArrayContext

func (*MainContext) EnterRule

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

func (*MainContext) ExitRule

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

func (*MainContext) GetParser

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

func (*MainContext) GetRuleContext

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

func (*MainContext) IsMainContext

func (*MainContext) IsMainContext()

func (*MainContext) Object

func (s *MainContext) Object() IObjectContext

func (*MainContext) SCALAR

func (s *MainContext) SCALAR() antlr.TerminalNode

func (*MainContext) ToStringTree

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

type ObjectContext

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

func NewEmptyObjectContext

func NewEmptyObjectContext() *ObjectContext

func NewObjectContext

func NewObjectContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *ObjectContext

func (*ObjectContext) Accept

func (s *ObjectContext) Accept(visitor antlr.ParseTreeVisitor) interface{}

func (*ObjectContext) EnterRule

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

func (*ObjectContext) ExitRule

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

func (*ObjectContext) GetParser

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

func (*ObjectContext) GetRuleContext

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

func (*ObjectContext) IsObjectContext

func (*ObjectContext) IsObjectContext()

func (*ObjectContext) Object_intern

func (s *ObjectContext) Object_intern() IObject_internContext

func (*ObjectContext) ToStringTree

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

type Object_internContext

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

func NewEmptyObject_internContext

func NewEmptyObject_internContext() *Object_internContext

func NewObject_internContext

func NewObject_internContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *Object_internContext

func (*Object_internContext) Accept

func (s *Object_internContext) Accept(visitor antlr.ParseTreeVisitor) interface{}

func (*Object_internContext) AllObject_item

func (s *Object_internContext) AllObject_item() []IObject_itemContext

func (*Object_internContext) EnterRule

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

func (*Object_internContext) ExitRule

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

func (*Object_internContext) GetParser

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

func (*Object_internContext) GetRuleContext

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

func (*Object_internContext) IsObject_internContext

func (*Object_internContext) IsObject_internContext()

func (*Object_internContext) Object_item

func (s *Object_internContext) Object_item(i int) IObject_itemContext

func (*Object_internContext) ToStringTree

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

type Object_itemContext

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

func NewEmptyObject_itemContext

func NewEmptyObject_itemContext() *Object_itemContext

func NewObject_itemContext

func NewObject_itemContext(parser antlr.Parser, parent antlr.ParserRuleContext, invokingState int) *Object_itemContext

func (*Object_itemContext) Accept

func (s *Object_itemContext) Accept(visitor antlr.ParseTreeVisitor) interface{}

func (*Object_itemContext) AllSCALAR

func (s *Object_itemContext) AllSCALAR() []antlr.TerminalNode

func (*Object_itemContext) Array

func (s *Object_itemContext) Array() IArrayContext

func (*Object_itemContext) EnterRule

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

func (*Object_itemContext) ExitRule

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

func (*Object_itemContext) GetParser

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

func (*Object_itemContext) GetRuleContext

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

func (*Object_itemContext) IsObject_itemContext

func (*Object_itemContext) IsObject_itemContext()

func (*Object_itemContext) Object

func (s *Object_itemContext) Object() IObjectContext

func (*Object_itemContext) SCALAR

func (*Object_itemContext) ToStringTree

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

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL