aboutsummaryrefslogtreecommitdiff
path: root/model/types.go
diff options
context:
space:
mode:
authorNeonXP <i@neonxp.dev>2022-11-21 04:31:56 +0300
committerNeonXP <i@neonxp.dev>2022-11-21 04:31:56 +0300
commit4054a50ce4232ebfc4dae043863ad96d46b25b43 (patch)
tree4ee57f8b0b5f66b142bb3898ba6e8162cb1b2a01 /model/types.go
parent4934a51c69e1975dc808e094e113b187ebb2c328 (diff)
Better interfacev0.0.3
Diffstat (limited to 'model/types.go')
-rw-r--r--model/types.go16
1 files changed, 7 insertions, 9 deletions
diff --git a/model/types.go b/model/types.go
index 10e60fa..bba7527 100644
--- a/model/types.go
+++ b/model/types.go
@@ -3,18 +3,16 @@ package model
type NodeType string
const (
- StringNode NodeType = "string"
- NumberNode NodeType = "number"
- ObjectNode NodeType = "object"
- ArrayNode NodeType = "array"
- BooleanNode NodeType = "boolean"
- NullNode NodeType = "null"
+ StringType NodeType = "string"
+ NumberType NodeType = "number"
+ ObjectType NodeType = "object"
+ ArrayType NodeType = "array"
+ BooleanType NodeType = "boolean"
+ NullType NodeType = "null"
)
-type NodeObjectValue map[string]*Node
+type NodeObjectValue map[string]Node
func (n NodeObjectValue) Set(k string, v any) {
n[k] = NewNode(v)
}
-
-type NodeArrayValue []*Node