expr

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2018 License: MIT Imports: 2 Imported by: 0

Documentation ¶

Index ¶

Constants ¶

This section is empty.

Variables ¶

This section is empty.

Functions ¶

This section is empty.

Types ¶

type Array ¶

type Array struct {
	Items []node.Node
}

Array node

func NewArray ¶

func NewArray(Items []node.Node) *Array

NewArray node constuctor

func (*Array) Attributes ¶

func (n *Array) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Array) Walk ¶

func (n *Array) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ArrayDimFetch ¶

type ArrayDimFetch struct {
	Variable node.Node
	Dim      node.Node
}

ArrayDimFetch node

func NewArrayDimFetch ¶

func NewArrayDimFetch(Variable node.Node, Dim node.Node) *ArrayDimFetch

NewArrayDimFetch node constuctor

func (*ArrayDimFetch) Attributes ¶

func (n *ArrayDimFetch) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ArrayDimFetch) Walk ¶

func (n *ArrayDimFetch) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ArrayItem ¶

type ArrayItem struct {
	ByRef bool
	Key   node.Node
	Val   node.Node
}

ArrayItem node

func NewArrayItem ¶

func NewArrayItem(Key node.Node, Val node.Node, ByRef bool) *ArrayItem

NewArrayItem node constuctor

func (*ArrayItem) Attributes ¶

func (n *ArrayItem) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ArrayItem) Walk ¶

func (n *ArrayItem) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type BitwiseNot ¶

type BitwiseNot struct {
	Expr node.Node
}

BitwiseNot node

func NewBitwiseNot ¶

func NewBitwiseNot(Expression node.Node) *BitwiseNot

NewBitwiseNot node constuctor

func (*BitwiseNot) Attributes ¶

func (n *BitwiseNot) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*BitwiseNot) Walk ¶

func (n *BitwiseNot) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type BooleanNot ¶

type BooleanNot struct {
	Expr node.Node
}

BooleanNot node

func NewBooleanNot ¶

func NewBooleanNot(Expression node.Node) *BooleanNot

NewBooleanNot node constuctor

func (*BooleanNot) Attributes ¶

func (n *BooleanNot) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*BooleanNot) Walk ¶

func (n *BooleanNot) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ClassConstFetch ¶

type ClassConstFetch struct {
	Class        node.Node
	ConstantName node.Node
}

ClassConstFetch node

func NewClassConstFetch ¶

func NewClassConstFetch(Class node.Node, ConstantName node.Node) *ClassConstFetch

NewClassConstFetch node constuctor

func (*ClassConstFetch) Attributes ¶

func (n *ClassConstFetch) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ClassConstFetch) Walk ¶

func (n *ClassConstFetch) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Clone ¶

type Clone struct {
	Expr node.Node
}

Clone node

func NewClone ¶

func NewClone(Expression node.Node) *Clone

NewClone node constuctor

func (*Clone) Attributes ¶

func (n *Clone) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Clone) Walk ¶

func (n *Clone) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Closure ¶

type Closure struct {
	ReturnsRef    bool
	Static        bool
	PhpDocComment string
	Params        []node.Node
	Uses          []node.Node
	ReturnType    node.Node
	Stmts         []node.Node
}

Closure node

func NewClosure ¶

func NewClosure(Params []node.Node, Uses []node.Node, ReturnType node.Node, Stmts []node.Node, Static bool, ReturnsRef bool, PhpDocComment string) *Closure

NewClosure node constuctor

func (*Closure) Attributes ¶

func (n *Closure) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Closure) Walk ¶

func (n *Closure) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ClosureUse ¶ added in v0.2.0

type ClosureUse struct {
	ByRef    bool
	Variable node.Node
}

ClosureUse node

func NewClosureUse ¶ added in v0.2.0

func NewClosureUse(Variable node.Node, ByRef bool) *ClosureUse

NewClosureUse node constuctor

func (*ClosureUse) Attributes ¶ added in v0.2.0

func (n *ClosureUse) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ClosureUse) Walk ¶ added in v0.2.0

func (n *ClosureUse) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ConstFetch ¶

type ConstFetch struct {
	Constant node.Node
}

ConstFetch node

func NewConstFetch ¶

func NewConstFetch(Constant node.Node) *ConstFetch

NewConstFetch node constuctor

func (*ConstFetch) Attributes ¶

func (n *ConstFetch) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ConstFetch) Walk ¶

func (n *ConstFetch) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Die ¶ added in v0.2.0

type Die struct {
	Expr node.Node
}

Die node

func NewDie ¶ added in v0.2.0

func NewDie(Expr node.Node) *Die

NewDie node constuctor

func (*Die) Attributes ¶ added in v0.2.0

func (n *Die) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Die) Walk ¶ added in v0.2.0

func (n *Die) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Empty ¶

type Empty struct {
	Expr node.Node
}

Empty node

func NewEmpty ¶

func NewEmpty(Expression node.Node) *Empty

NewEmpty node constuctor

func (*Empty) Attributes ¶

func (n *Empty) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Empty) Walk ¶

func (n *Empty) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ErrorSuppress ¶

type ErrorSuppress struct {
	Expr node.Node
}

ErrorSuppress node

func NewErrorSuppress ¶

func NewErrorSuppress(Expression node.Node) *ErrorSuppress

NewErrorSuppress node constuctor

func (*ErrorSuppress) Attributes ¶

func (n *ErrorSuppress) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ErrorSuppress) Walk ¶

func (n *ErrorSuppress) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Eval ¶

type Eval struct {
	Expr node.Node
}

Eval node

func NewEval ¶

func NewEval(Expression node.Node) *Eval

NewEval node constuctor

func (*Eval) Attributes ¶

func (n *Eval) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Eval) Walk ¶

func (n *Eval) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Exit ¶

type Exit struct {
	Expr node.Node
}

Exit node

func NewExit ¶

func NewExit(Expr node.Node) *Exit

NewExit node constuctor

func (*Exit) Attributes ¶

func (n *Exit) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Exit) Walk ¶

func (n *Exit) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type FunctionCall ¶

type FunctionCall struct {
	Function  node.Node
	Arguments []node.Node
}

FunctionCall node

func NewFunctionCall ¶

func NewFunctionCall(Function node.Node, Arguments []node.Node) *FunctionCall

NewFunctionCall node constuctor

func (*FunctionCall) Attributes ¶

func (n *FunctionCall) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*FunctionCall) Walk ¶

func (n *FunctionCall) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Include ¶

type Include struct {
	Expr node.Node
}

Include node

func NewInclude ¶

func NewInclude(Expression node.Node) *Include

NewInclude node constuctor

func (*Include) Attributes ¶

func (n *Include) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Include) Walk ¶

func (n *Include) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type IncludeOnce ¶

type IncludeOnce struct {
	Expr node.Node
}

IncludeOnce node

func NewIncludeOnce ¶

func NewIncludeOnce(Expression node.Node) *IncludeOnce

NewIncludeOnce node constuctor

func (*IncludeOnce) Attributes ¶

func (n *IncludeOnce) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*IncludeOnce) Walk ¶

func (n *IncludeOnce) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type InstanceOf ¶

type InstanceOf struct {
	Expr  node.Node
	Class node.Node
}

InstanceOf node

func NewInstanceOf ¶

func NewInstanceOf(Expr node.Node, Class node.Node) *InstanceOf

NewInstanceOf node constuctor

func (*InstanceOf) Attributes ¶

func (n *InstanceOf) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*InstanceOf) Walk ¶

func (n *InstanceOf) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Isset ¶

type Isset struct {
	Variables []node.Node
}

Isset node

func NewIsset ¶

func NewIsset(Variables []node.Node) *Isset

NewIsset node constuctor

func (*Isset) Attributes ¶

func (n *Isset) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Isset) Walk ¶

func (n *Isset) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type List ¶

type List struct {
	Items []node.Node
}

List node

func NewList ¶

func NewList(Items []node.Node) *List

NewList node constuctor

func (*List) Attributes ¶

func (n *List) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*List) Walk ¶

func (n *List) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type MethodCall ¶

type MethodCall struct {
	Variable  node.Node
	Method    node.Node
	Arguments []node.Node
}

MethodCall node

func NewMethodCall ¶

func NewMethodCall(Variable node.Node, Method node.Node, Arguments []node.Node) *MethodCall

NewMethodCall node constuctor

func (*MethodCall) Attributes ¶

func (n *MethodCall) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*MethodCall) Walk ¶

func (n *MethodCall) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type New ¶

type New struct {
	Class     node.Node
	Arguments []node.Node
}

New node

func NewNew ¶

func NewNew(Class node.Node, Arguments []node.Node) *New

NewNew node constuctor

func (*New) Attributes ¶

func (n *New) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*New) Walk ¶

func (n *New) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type PostDec ¶

type PostDec struct {
	Variable node.Node
}

PostDec node

func NewPostDec ¶

func NewPostDec(Variable node.Node) *PostDec

NewPostDec node constuctor

func (*PostDec) Attributes ¶

func (n *PostDec) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*PostDec) Walk ¶

func (n *PostDec) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type PostInc ¶

type PostInc struct {
	Variable node.Node
}

PostInc node

func NewPostInc ¶

func NewPostInc(Variable node.Node) *PostInc

NewPostInc node constuctor

func (*PostInc) Attributes ¶

func (n *PostInc) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*PostInc) Walk ¶

func (n *PostInc) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type PreDec ¶

type PreDec struct {
	Variable node.Node
}

PreDec node

func NewPreDec ¶

func NewPreDec(Variable node.Node) *PreDec

NewPreDec node constuctor

func (*PreDec) Attributes ¶

func (n *PreDec) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*PreDec) Walk ¶

func (n *PreDec) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type PreInc ¶

type PreInc struct {
	Variable node.Node
}

PreInc node

func NewPreInc ¶

func NewPreInc(Variable node.Node) *PreInc

NewPreInc node constuctor

func (*PreInc) Attributes ¶

func (n *PreInc) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*PreInc) Walk ¶

func (n *PreInc) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Print ¶

type Print struct {
	Expr node.Node
}

Print node

func NewPrint ¶

func NewPrint(Expression node.Node) *Print

NewPrint node constuctor

func (*Print) Attributes ¶

func (n *Print) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Print) Walk ¶

func (n *Print) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type PropertyFetch ¶

type PropertyFetch struct {
	Variable node.Node
	Property node.Node
}

PropertyFetch node

func NewPropertyFetch ¶

func NewPropertyFetch(Variable node.Node, Property node.Node) *PropertyFetch

NewPropertyFetch node constuctor

func (*PropertyFetch) Attributes ¶

func (n *PropertyFetch) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*PropertyFetch) Walk ¶

func (n *PropertyFetch) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Require ¶

type Require struct {
	Expr node.Node
}

Require node

func NewRequire ¶

func NewRequire(Expression node.Node) *Require

NewRequire node constuctor

func (*Require) Attributes ¶

func (n *Require) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Require) Walk ¶

func (n *Require) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type RequireOnce ¶

type RequireOnce struct {
	Expr node.Node
}

RequireOnce node

func NewRequireOnce ¶

func NewRequireOnce(Expression node.Node) *RequireOnce

NewRequireOnce node constuctor

func (*RequireOnce) Attributes ¶

func (n *RequireOnce) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*RequireOnce) Walk ¶

func (n *RequireOnce) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ShellExec ¶

type ShellExec struct {
	Parts []node.Node
}

ShellExec node

func NewShellExec ¶

func NewShellExec(Parts []node.Node) *ShellExec

NewShellExec node constuctor

func (*ShellExec) Attributes ¶

func (n *ShellExec) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ShellExec) Walk ¶

func (n *ShellExec) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ShortArray ¶

type ShortArray struct {
	Items []node.Node
}

ShortArray node

func NewShortArray ¶

func NewShortArray(Items []node.Node) *ShortArray

NewShortArray node constuctor

func (*ShortArray) Attributes ¶

func (n *ShortArray) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ShortArray) Walk ¶

func (n *ShortArray) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type ShortList ¶

type ShortList struct {
	Items []node.Node
}

ShortList node

func NewShortList ¶

func NewShortList(Items []node.Node) *ShortList

NewShortList node constuctor

func (*ShortList) Attributes ¶

func (n *ShortList) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*ShortList) Walk ¶

func (n *ShortList) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type StaticCall ¶

type StaticCall struct {
	Class     node.Node
	Call      node.Node
	Arguments []node.Node
}

StaticCall node

func NewStaticCall ¶

func NewStaticCall(Class node.Node, Call node.Node, Arguments []node.Node) *StaticCall

NewStaticCall node constuctor

func (*StaticCall) Attributes ¶

func (n *StaticCall) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*StaticCall) Walk ¶

func (n *StaticCall) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type StaticPropertyFetch ¶

type StaticPropertyFetch struct {
	Class    node.Node
	Property node.Node
}

StaticPropertyFetch node

func NewStaticPropertyFetch ¶

func NewStaticPropertyFetch(Class node.Node, Property node.Node) *StaticPropertyFetch

NewStaticPropertyFetch node constuctor

func (*StaticPropertyFetch) Attributes ¶

func (n *StaticPropertyFetch) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*StaticPropertyFetch) Walk ¶

func (n *StaticPropertyFetch) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Ternary ¶

type Ternary struct {
	Condition node.Node
	IfTrue    node.Node
	IfFalse   node.Node
}

Ternary node

func NewTernary ¶

func NewTernary(Condition node.Node, IfTrue node.Node, IfFalse node.Node) *Ternary

NewTernary node constuctor

func (*Ternary) Attributes ¶

func (n *Ternary) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Ternary) Walk ¶

func (n *Ternary) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type UnaryMinus ¶

type UnaryMinus struct {
	Expr node.Node
}

UnaryMinus node

func NewUnaryMinus ¶

func NewUnaryMinus(Expression node.Node) *UnaryMinus

NewUnaryMinus node constuctor

func (*UnaryMinus) Attributes ¶

func (n *UnaryMinus) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*UnaryMinus) Walk ¶

func (n *UnaryMinus) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type UnaryPlus ¶

type UnaryPlus struct {
	Expr node.Node
}

UnaryPlus node

func NewUnaryPlus ¶

func NewUnaryPlus(Expression node.Node) *UnaryPlus

NewUnaryPlus node constuctor

func (*UnaryPlus) Attributes ¶

func (n *UnaryPlus) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*UnaryPlus) Walk ¶

func (n *UnaryPlus) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Variable ¶

type Variable struct {
	VarName node.Node
}

Variable node

func NewVariable ¶

func NewVariable(VarName node.Node) *Variable

NewVariable node constuctor

func (*Variable) Attributes ¶

func (n *Variable) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Variable) SetVarName ¶

func (n *Variable) SetVarName(VarName node.Node)

SetVarName reset var name

func (*Variable) Walk ¶

func (n *Variable) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type Yield ¶

type Yield struct {
	Key   node.Node
	Value node.Node
}

Yield node

func NewYield ¶

func NewYield(Key node.Node, Value node.Node) *Yield

NewYield node constuctor

func (*Yield) Attributes ¶

func (n *Yield) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*Yield) Walk ¶

func (n *Yield) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

type YieldFrom ¶

type YieldFrom struct {
	Expr node.Node
}

YieldFrom node

func NewYieldFrom ¶

func NewYieldFrom(Expression node.Node) *YieldFrom

NewYieldFrom node constuctor

func (*YieldFrom) Attributes ¶

func (n *YieldFrom) Attributes() map[string]interface{}

Attributes returns node attributes as map

func (*YieldFrom) Walk ¶

func (n *YieldFrom) Walk(v walker.Visitor)

Walk traverses nodes Walk is invoked recursively until v.EnterNode returns true

Directories ¶

Path Synopsis

Jump to

Keyboard shortcuts

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