Versions in this module Expand all Collapse all v0 v0.13.2 Aug 14, 2019 v0.13.1 Aug 14, 2019 v0.13.0 Aug 6, 2019 Changes in this version + var A = NewAny() + var B = NewBoolean() + var N = NewNumber() + var S = NewString() + func Compare(a, b Type) int + func Contains(a, b Type) bool + func Nil(a Type) bool + func Sprint(x Type) string + type Any []Type + func NewAny(of ...Type) Any + func (t Any) Contains(other Type) bool + func (t Any) MarshalJSON() ([]byte, error) + func (t Any) Merge(other Type) Any + func (t Any) String() string + func (t Any) Union(other Any) Any + type Array struct + func NewArray(static []Type, dynamic Type) *Array + func (t *Array) Dynamic() Type + func (t *Array) Len() int + func (t *Array) MarshalJSON() ([]byte, error) + func (t *Array) Select(pos int) Type + func (t *Array) String() string + type Boolean struct + func NewBoolean() Boolean + func (t Boolean) MarshalJSON() ([]byte, error) + func (t Boolean) String() string + type DynamicProperty struct + Key Type + Value Type + func NewDynamicProperty(key, value Type) *DynamicProperty + func (p *DynamicProperty) MarshalJSON() ([]byte, error) + func (p *DynamicProperty) String() string + type Function struct + func NewFunction(args []Type, result Type) *Function + func (t *Function) Args() []Type + func (t *Function) MarshalJSON() ([]byte, error) + func (t *Function) Result() Type + func (t *Function) String() string + func (t *Function) Union(other *Function) *Function + type Null struct + func NewNull() Null + func (t Null) MarshalJSON() ([]byte, error) + func (t Null) String() string + type Number struct + func NewNumber() Number + func (Number) String() string + func (t Number) MarshalJSON() ([]byte, error) + type Object struct + func NewObject(static []*StaticProperty, dynamic *DynamicProperty) *Object + func (t *Object) DynamicValue() Type + func (t *Object) Keys() []interface{} + func (t *Object) MarshalJSON() ([]byte, error) + func (t *Object) Select(name interface{}) Type + func (t *Object) String() string + type Set struct + func NewSet(of Type) *Set + func (t *Set) MarshalJSON() ([]byte, error) + func (t *Set) String() string + type StaticProperty struct + Key interface{} + Value Type + func NewStaticProperty(key interface{}, value Type) *StaticProperty + func (p *StaticProperty) MarshalJSON() ([]byte, error) + type String struct + func NewString() String + func (t String) MarshalJSON() ([]byte, error) + func (t String) String() string + type Type interface + String func() string + func Args(x ...Type) []Type + func Keys(a Type) Type + func Or(a, b Type) Type + func Select(a Type, x interface{}) Type + func TypeOf(x interface{}) Type + func Values(a Type) Type