jsonx

package
v0.0.0-...-dd653cf Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DropWrapAll

func DropWrapAll(n *Node)

func WrapAll

func WrapAll(n *Node, termWidth int)

Types

type Node

type Node struct {
	Prev, Next, End *Node

	Collapsed *Node
	Depth     uint8
	Key       []byte
	Value     []byte
	Size      int
	Chunk     []byte
	ChunkEnd  *Node
	Comma     bool
	Index     int
	// contains filtered or unexported fields
}

func Parse

func Parse(data []byte) (head *Node, err error)

func (*Node) Children

func (n *Node) Children() ([]string, []*Node)

func (*Node) Collapse

func (n *Node) Collapse() *Node

func (*Node) CollapseRecursively

func (n *Node) CollapseRecursively()

func (*Node) Expand

func (n *Node) Expand()

func (*Node) ExpandRecursively

func (n *Node) ExpandRecursively(level, maxLevel int)

func (*Node) FindChildByIndex

func (n *Node) FindChildByIndex(index int) *Node

func (*Node) FindChildByKey

func (n *Node) FindChildByKey(key string) *Node

func (*Node) HasChildren

func (n *Node) HasChildren() bool

func (*Node) IsCollapsed

func (n *Node) IsCollapsed() bool

func (*Node) IsWrap

func (n *Node) IsWrap() bool

func (*Node) Parent

func (n *Node) Parent() *Node

func (*Node) PrettyPrint

func (n *Node) PrettyPrint() string

func (*Node) String

func (n *Node) String() string

Jump to

Keyboard shortcuts

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