Documentation
¶
Overview ¶
Package parser reads JSON tree snapshots and reconstructs the in-memory tree representation for comparison and display operations.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrEmptyInput = errors.New("empty tree structure") ErrInvalidFormat = errors.New("invalid tree format") ErrEmptyNodeName = errors.New("empty node name") ErrInvalidStructure = errors.New("invalid tree structure") )
Sentinel errors for parser operations
Functions ¶
This section is empty.
Types ¶
type Parser ¶
type Parser struct{}
Parser parses tree format text into node structure
type TreeParser ¶
type TreeParser interface {
Parse(reader io.Reader) (*models.Node, error)
ParseString(content string) (*models.Node, error)
}
TreeParser defines the interface for parsing tree structures
func NewParser ¶
func NewParser() TreeParser
NewParser creates a new parser and returns a TreeParser interface
Click to show internal directories.
Click to hide internal directories.