Help us shape the future of Go! Take the 2026 Go Developer Survey

xml

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2026 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Format

func Format(v any) (string, error)

func Parse

func Parse(raw string) (any, error)

Types

type Document

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

Document retains namespaces and mixed-content order independently of its convenient JSON-shaped read view. A document belongs to one scenario.

func FromMap

func FromMap(m map[string]any) (*Document, error)

func ParseDocument

func ParseDocument(raw string) (*Document, error)

func (*Document) CloneValue

func (d *Document) CloneValue() (any, error)

func (*Document) Comparable

func (d *Document) Comparable() any

Comparable includes expanded namespace names and ordered content. Namespace prefix spelling and formatting whitespace do not change element identity.

func (*Document) DataValue

func (d *Document) DataValue() any

func (*Document) MarshalJSON

func (d *Document) MarshalJSON() ([]byte, error)

func (*Document) Query

func (d *Document) Query(path string) (any, error)

func (*Document) Remove

func (d *Document) Remove(path string) error

func (*Document) Set

func (d *Document) Set(path string, val any) error

func (*Document) String

func (d *Document) String() string

Jump to

Keyboard shortcuts

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