jsonnode

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2024 License: MIT Imports: 7 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 []Node

func NewArray

func NewArray() *Array

func (*Array) Marshal added in v0.0.6

func (a *Array) Marshal() ([]byte, error)

func (*Array) Serialize added in v0.0.6

func (a *Array) Serialize() json.RawMessage

func (*Array) String

func (a *Array) String() string

func (*Array) UnmarshalJSON

func (a *Array) UnmarshalJSON(data []byte) error

type Boolean

type Boolean bool

func (Boolean) Bool

func (b Boolean) Bool() bool

func (Boolean) Marshal added in v0.0.6

func (b Boolean) Marshal() ([]byte, error)

func (Boolean) Serialize added in v0.0.6

func (b Boolean) Serialize() json.RawMessage

func (Boolean) String

func (b Boolean) String() string

type Node

type Node interface {
	String() string
	Serialize() json.RawMessage
	Marshal() ([]byte, error) // extends Marshaler
	// contains filtered or unexported methods
}

type Null

type Null bool
const NULL Null = false

func (Null) Marshal added in v0.0.6

func (n Null) Marshal() ([]byte, error)

func (Null) Serialize added in v0.0.6

func (n Null) Serialize() json.RawMessage

func (Null) String

func (n Null) String() string

type Number

type Number json.Number

func (Number) Float64

func (n Number) Float64() (float64, error)

func (Number) Int64

func (n Number) Int64() (int64, error)

func (Number) Marshal added in v0.0.6

func (n Number) Marshal() ([]byte, error)

func (Number) Number

func (n Number) Number() json.Number

func (Number) Serialize added in v0.0.6

func (n Number) Serialize() json.RawMessage

func (Number) String

func (n Number) String() string

func (Number) Uint64

func (n Number) Uint64() (uint64, error)

type Object

type Object struct {
	// contains filtered or unexported fields
}

func NewObject

func NewObject() *Object

func (*Object) Get

func (o *Object) Get(key string) Node

func (*Object) KeyExists

func (o *Object) KeyExists(key string) bool

func (*Object) Keys

func (o *Object) Keys() []string

func (*Object) Marshal added in v0.0.6

func (o *Object) Marshal() ([]byte, error)

func (*Object) Put

func (o *Object) Put(key string, value Node)

func (*Object) Serialize added in v0.0.6

func (o *Object) Serialize() json.RawMessage

func (*Object) String

func (o *Object) String() string

func (*Object) UnmarshalJSON

func (o *Object) UnmarshalJSON(data []byte) error

type String

type String string

func (String) Marshal added in v0.0.6

func (s String) Marshal() ([]byte, error)

func (String) Serialize added in v0.0.6

func (s String) Serialize() json.RawMessage

func (String) String

func (s String) String() string

Jump to

Keyboard shortcuts

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