We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4ee72ef commit 1644362Copy full SHA for 1644362
bracket.go
@@ -31,6 +31,9 @@ type Node interface {
31
// Для всех остальных выводиться строковое представление ноды
32
String() string
33
34
+ // Int64 получение числового значение ноды
35
+ Int(address ...int) int
36
+
37
// Int64 получение числового значение ноды
38
Int64(address ...int) int64
39
// Bool получение булевного значение ноды
@@ -146,6 +149,11 @@ func (b bracketsNode) String() string {
146
149
return fmt.Sprintf("{%s}", val)
147
150
}
148
151
152
+func (b bracketsNode) Int(address ...int) int {
153
154
+ return int(b.Int64(address...))
155
+}
156
157
func (b bracketsNode) Int64(address ...int) int64 {
158
159
n, err := b.getNode(address)
0 commit comments