Versions in this module Expand all Collapse all v0 v0.2.1 Oct 23, 2019 Changes in this version type Tree + Duration int64 + Op string + Requires []struct{ ... } + Timeout int64 + Val interface{} v0.2.0 Mar 14, 2019 Changes in this version + var ErrBadType = errors.New("types are different") + var ErrNoNode = errors.New("Node is nil") + var ErrNoParentNode = errors.New("Node has no parent") + var ErrNotSupportedType = errors.New("type not supported") + var ErrOperator = errors.New("unknow operator") + var FallbackType = "fallback" + func GetNodePathFromContext(ctx context.Context) []string + type Operator func(requests map[string]interface{}, node *Tree) (*Tree, error) + type Tree struct + Content interface{} + ID int + Key string + Name string + Operator string + Order int + ParentID int + Value interface{} + func CreateTree(data []Tree) *Tree + func LoadTree(jsonTree []byte) (*Tree, error) + func (t *Tree) AddNode(node *Tree) + func (t *Tree) Context() context.Context + func (t *Tree) GetChild() []*Tree + func (t *Tree) GetParent() *Tree + func (t *Tree) Next(jsonRequest map[string]interface{}, config *TreeOptions) (*Tree, error) + func (t *Tree) Resolve(request map[string]interface{}, options ...func(t *TreeOptions)) (*Tree, error) + func (t *Tree) ResolveJSON(jsonRequest []byte, options ...func(t *TreeOptions)) (*Tree, error) + func (t *Tree) WithContext(ctx context.Context) *Tree + type TreeOptions struct + Operators map[string]Operator + OverrideExistingOperator bool + StopIfConvertingError bool