Documentation ¶
Index ¶
- Variables
- func GetIn(from core.Value, byPath []core.Value) (core.Value, error)
- func Parse(input interface{}) core.Value
- func SetIn(to core.Value, byPath []core.Value, value core.Value) error
- func ToBoolean(input core.Value) core.Value
- func Unmarshal(value json.RawMessage) (core.Value, error)
- type Array
- func (t *Array) Clone() core.Cloneable
- func (t *Array) Compare(other core.Value) int
- func (t *Array) Copy() core.Value
- func (t *Array) ForEach(predicate ArrayPredicate)
- func (t *Array) Get(idx Int) core.Value
- func (t *Array) Hash() uint64
- func (t *Array) IndexOf(item core.Value) Int
- func (t *Array) Insert(idx Int, value core.Value)
- func (t *Array) Length() Int
- func (t *Array) MarshalJSON() ([]byte, error)
- func (t *Array) Push(item core.Value)
- func (t *Array) RemoveAt(idx Int)
- func (t *Array) Set(idx Int, value core.Value) error
- func (t *Array) Slice(from, to Int) *Array
- func (t *Array) Sort() *Array
- func (t *Array) String() string
- func (t *Array) Type() core.Type
- func (t *Array) Unwrap() interface{}
- type ArrayPredicate
- type Binary
- type Boolean
- type DateTime
- type Float
- type HTMLDocument
- type HTMLNode
- type Int
- type Object
- func (t *Object) Clone() core.Cloneable
- func (t *Object) Compare(other core.Value) int
- func (t *Object) Copy() core.Value
- func (t *Object) ForEach(predicate ObjectPredicate)
- func (t *Object) Get(key String) (core.Value, Boolean)
- func (t *Object) GetIn(path []core.Value) (core.Value, error)
- func (t *Object) Hash() uint64
- func (t *Object) Keys() []string
- func (t *Object) Length() Int
- func (t *Object) MarshalJSON() ([]byte, error)
- func (t *Object) Remove(key String)
- func (t *Object) Set(key String, value core.Value)
- func (t *Object) SetIn(path []core.Value, value core.Value) error
- func (t *Object) String() string
- func (t *Object) Type() core.Type
- func (t *Object) Unwrap() interface{}
- type ObjectPredicate
- type ObjectProperty
- type String
- func (t String) Compare(other core.Value) int
- func (t String) Concat(other core.Value) String
- func (t String) Contains(other String) Boolean
- func (t String) Copy() core.Value
- func (t String) Hash() uint64
- func (t String) IndexOf(other String) Int
- func (t String) Length() Int
- func (t String) MarshalJSON() ([]byte, error)
- func (t String) String() string
- func (t String) Type() core.Type
- func (t String) Unwrap() interface{}
Constants ¶
This section is empty.
Variables ¶
View Source
var EmptyString = String("")
View Source
var False = Boolean(false)
View Source
var None = &none{}
View Source
var SpaceString = String(" ")
View Source
var True = Boolean(true)
View Source
var ZeroDateTime = DateTime{ time.Time{}, }
View Source
var ZeroFloat = Float(0.0)
View Source
var ZeroInt = Int(0)
Functions ¶
Types ¶
type Array ¶
type Array struct {
// contains filtered or unexported fields
}
func NewArrayWith ¶
func (*Array) ForEach ¶
func (t *Array) ForEach(predicate ArrayPredicate)
func (*Array) MarshalJSON ¶
type Binary ¶
type Binary struct {
// contains filtered or unexported fields
}
func (*Binary) MarshalJSON ¶
type Boolean ¶
type Boolean bool
func IsCloneable ¶
func NewBoolean ¶
func ParseBoolean ¶
func ParseBooleanP ¶
func ParseBooleanP(input interface{}) Boolean
func (Boolean) MarshalJSON ¶
type DateTime ¶
func NewCurrentDateTime ¶
func NewCurrentDateTime() DateTime
func NewDateTime ¶
func ParseDateTime ¶
func ParseDateTimeP ¶
func ParseDateTimeP(input interface{}) DateTime
func ParseDateTimeWith ¶
func (DateTime) MarshalJSON ¶
type Float ¶
type Float float64
func ParseFloat ¶
func ParseFloatP ¶
func ParseFloatP(input interface{}) Float
func (Float) MarshalJSON ¶
type HTMLDocument ¶
type HTMLNode ¶
type HTMLNode interface { core.Value NodeType() Int NodeName() String Length() Int InnerText() String InnerHTML() String Value() core.Value GetAttributes() core.Value GetAttribute(name String) core.Value GetChildNodes() core.Value GetChildNode(idx Int) core.Value QuerySelector(selector String) core.Value QuerySelectorAll(selector String) core.Value InnerHTMLBySelector(selector String) String InnerHTMLBySelectorAll(selector String) *Array InnerTextBySelector(selector String) String InnerTextBySelectorAll(selector String) *Array CountBySelector(selector String) Int }
type Object ¶
type Object struct {
// contains filtered or unexported fields
}
func NewObjectWith ¶
func NewObjectWith(props ...*ObjectProperty) *Object
func (*Object) ForEach ¶
func (t *Object) ForEach(predicate ObjectPredicate)
func (*Object) MarshalJSON ¶
type ObjectProperty ¶
type ObjectProperty struct {
// contains filtered or unexported fields
}
func NewObjectProperty ¶
func NewObjectProperty(name string, value core.Value) *ObjectProperty
type String ¶
type String string
func NewStringFromRunes ¶
func ParseString ¶
func ParseStringP ¶
func ParseStringP(input interface{}) String
func (String) MarshalJSON ¶
Click to show internal directories.
Click to hide internal directories.