Added metadata to node

This commit is contained in:
NeonXP 2022-11-17 19:46:17 +03:00
parent eb26d597c6
commit 59e421989e
No known key found for this signature in database
GPG Key ID: B0DA6283C40CB2CB
1 changed files with 4 additions and 0 deletions

View File

@ -9,6 +9,7 @@ import (
// Node of JSON tree
type Node struct {
Type NodeType
Meta Meta
stringValue string
numberValue float64
objectValue NodeObjectValue
@ -143,3 +144,6 @@ func (n *Node) Len() (int, error) {
return 0, fmt.Errorf("merge not implemented for type %s", n.Type)
}
}
// Meta represents node metadata
type Meta map[string]any