Exemple #1
0
// NewRuleParser returns a new instance of RuleParser for given input string
func NewRuleParser(input string) *RuleParser {
	return &RuleParser{Lexer: lexer.New(input), GeneratedRule: &hook.Rules{}}
}
Exemple #2
0
// NewArgumentParser returns a new instance of ArgumentParser for given input string
func NewArgumentParser(input string) *ArgumentParser {
	return &ArgumentParser{Lexer: lexer.New(input), GeneratedArguments: make([]hook.Argument, 0)}
}