json

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewScanState

func NewScanState(in byte) *state

func SaneValueStart

func SaneValueStart(c byte) bool

Types

type ErrBadJSONValue

type ErrBadJSONValue struct {
	Char byte
}

TODO: we also have ErrBadJSONValue :)

func (ErrBadJSONValue) Error

func (e ErrBadJSONValue) Error() string

type ErrBadValue

type ErrBadValue struct {
	Value string
}

func (ErrBadValue) Error

func (e ErrBadValue) Error() string

type ErrInternal

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

TODO: unwrappable

func (ErrInternal) Error

func (e ErrInternal) Error() string

type ErrScanNotObject

type ErrScanNotObject struct {
	On byte
}

func (ErrScanNotObject) Error

func (ErrScanNotObject) Error() string

type JSON

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

func New

func New(r io.Reader) *JSON

func (*JSON) MoveOff

func (j *JSON) MoveOff()

func (*JSON) Next

func (j *JSON) Next() (c byte, e error)

func (*JSON) Peek

func (j *JSON) Peek() byte

func (*JSON) ScanForKey

func (j *JSON) ScanForKey(k string) (bool, error)

func (*JSON) ScanForKeyValue

func (j *JSON) ScanForKeyValue(k string) (bool, error)

func (*JSON) WriteCurrentTo

func (j *JSON) WriteCurrentTo(w io.Writer, includeDeliminators bool) (int, error)

Jump to

Keyboard shortcuts

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