Documentation
¶
Overview ¶
Package jsonpointer-go provides functions to use jsonpointer defined by the RFC 6902 in Golang.
Index ¶
Constants ¶
View Source
const ( JSONPointerEmptyPointer = "" JSONPointerSeparatorToken = "/" JSONPointerEscapeToken = "~" JSONPointerSlashEncoded = "~1" JSONPointerTildaEncoded = "~0" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type JSONObject ¶
JSONObject is a type alias for a map with string keys and values of any type
type JSONPointer ¶
type JSONPointer struct {
// contains filtered or unexported fields
}
JSONPointer struct holds the parsed reference tokens of a JSON Pointer
func NewJSONPointer ¶
func NewJSONPointer(jsonPointer string) (*JSONPointer, error)
NewJSONPointer creates a new JSONPointer instance from a JSON Pointer string
func (*JSONPointer) GetValue ¶
func (jp *JSONPointer) GetValue(document JSONObject) (any, error)
GetValue retrieves the value from the JSON document based on the JSON Pointer
Click to show internal directories.
Click to hide internal directories.