Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LanguageNode ¶
LanguageNode represents a node in the AST.
type SyntaxTree ¶
type SyntaxTree struct {
// contains filtered or unexported fields
}
SyntaxTree is a concrete implementation of the AST.
func (*SyntaxTree) Evaluate ¶
func (t *SyntaxTree) Evaluate() string
Evaluate returns the recursively evaluated SyntaxTree.
func (*SyntaxTree) SubstituteVars ¶
func (t *SyntaxTree) SubstituteVars(vars map[string]interface{}) error
SubstituteVars performs recursive vars substitution on the SyntaxTree.
type TokenTree ¶
type TokenTree struct {
// contains filtered or unexported fields
}
TokenTree represents a tree of token chunks.
func BuildTokenTree ¶
BuildTokenTree builds a tree of tokens from a template string.
func (*TokenTree) Parse ¶
func (tt *TokenTree) Parse() (LanguageNode, error)
Parse parses the TokenTree and returns the AST built from it.
Click to show internal directories.
Click to hide internal directories.