@@ -46,8 +46,8 @@ type PathValue interface {
4646// NodesType defines a node list (a list of JSON values) for a function
4747// expression parameters or results, as defined by [RFC 9535 Section 2.4.1].
4848// It can also be used in filter expressions. The underlying types should be
49- // string, integer, float, [json.Number], nil, true, false, []any , or
50- // map[ string]any . Interfaces implemented:
49+ // string, integer, float, [json.Number], nil, true, false, slice , or
50+ // string-keyed map . Interfaces implemented:
5151//
5252// - [PathValue]
5353// - [fmt.Stringer]
@@ -57,7 +57,7 @@ type NodesType []any
5757
5858// Nodes creates a NodesType that contains val, all of which should be the Go
5959// equivalent of the JSON data types: string, integer, float, [json.Number],
60- // nil, true, false, []any , or map[ string]any .
60+ // nil, true, false, slice , or string-keyed map .
6161func Nodes (val ... any ) NodesType {
6262 return NodesType (val )
6363}
@@ -137,8 +137,8 @@ func (LogicalType) FuncType() FuncType { return FuncLogical }
137137// LogicalFrom converts value to a [LogicalType] and panics if it cannot. Use
138138// in [github.com/theory/jsonpath/registry.Registry.Register] [Evaluator]
139139// functions. Avoid the panic by returning an error from the accompanying
140- // [Validator] function when [FuncExprArg.ConvertsToLogical ] returns false for
141- // the [FuncExprArg] that returns value.
140+ // [Validator] function when [FuncExprArg.ConvertsTo ] returns false for the
141+ // [FuncExprArg] that returns value.
142142//
143143// Converts each implementation of [PathValue] as follows:
144144// - [LogicalType]: returns value
@@ -170,7 +170,7 @@ func (lt LogicalType) writeTo(buf *strings.Builder) {
170170// ValueType encapsulates a JSON value for a function expression parameter or
171171// result, as defined by [RFC 9535 Section 2.4.1]. It can also be used as in
172172// filter expression. The underlying value should be a string, integer,
173- // [json.Number], float, nil, true, false, []any , or map[ string]any . A nil
173+ // [json.Number], float, nil, true, false, slice , or string-keyed map . A nil
174174// ValueType pointer indicates no value. Interfaces implemented:
175175//
176176// - [PathValue]
@@ -184,7 +184,7 @@ type ValueType struct {
184184
185185// Value returns a new [ValueType] for val, which must be the Go equivalent of
186186// a JSON data type: string, integer, float, [json.Number], nil, true, false,
187- // []any , or map[ string]any .
187+ // slice , or string-keyed map .
188188func Value (val any ) * ValueType {
189189 return & ValueType {val }
190190}
@@ -201,8 +201,8 @@ func (*ValueType) FuncType() FuncType { return FuncValue }
201201// ValueFrom converts value to a [ValueType] and panics if it cannot. Use in
202202// [github.com/theory/jsonpath/registry.Registry.Register] [Evaluator]
203203// functions. Avoid the panic by returning an error from the accompanying
204- // [Validator] function when [FuncExprArg.ConvertsToValue ] returns false for
205- // the [FuncExprArg] that returns value.
204+ // [Validator] function when [FuncExprArg.ConvertsTo ] returns false for the
205+ // [FuncExprArg] that returns value.
206206//
207207// Converts each implementation of [PathValue] as follows:
208208// - [ValueType]: returns value
0 commit comments