parser

package
v0.0.0-...-72c54ed Latest Latest
Warning

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

Go to latest
Published: Dec 31, 2015 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArgumentParser

type ArgumentParser struct {
	Lexer              *lexer.Lexer
	Position           int
	GeneratedArguments []hook.Argument
}

ArgumentParser is a struct that contains Lexer and the GeneratedArguments

func NewArgumentParser

func NewArgumentParser(input string) *ArgumentParser

NewArgumentParser returns a new instance of ArgumentParser for given input string

func (*ArgumentParser) Error

func (parser *ArgumentParser) Error(err string, tokenPos int) error

func (*ArgumentParser) Parse

func (parser *ArgumentParser) Parse() error

Parse performs lexical analysis of the input string and generates arguments based on the lexer output

type RuleParser

type RuleParser struct {
	Lexer         *lexer.Lexer
	Position      int
	GeneratedRule *hook.Rules
}

RuleParser is a struct that contains Lexer and the GeneratedRule

func NewRuleParser

func NewRuleParser(input string) *RuleParser

NewRuleParser returns a new instance of RuleParser for given input string

func (*RuleParser) Error

func (parser *RuleParser) Error(err string, tokenPos int) error

func (*RuleParser) Parse

func (parser *RuleParser) Parse() error

Parse performs lexical analysis of the input string and generates rules based on the lexer output

Jump to

Keyboard shortcuts

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