Documentation ¶
Index ¶
- type AfterLastIndexToken
- type AfterModifier
- type ArrayIndex
- type ArrayInsertion
- type ArrayInsertionIndex
- type BeforeModifier
- type DescriptiveOp
- type ErrOp
- type FindOp
- type IndexToken
- type KeyToken
- type MatchingIndexToken
- type Modifier
- type NextModifier
- type Op
- type OpDefinition
- type OpMissingIndexErr
- type Ops
- type Pointer
- type PrevModifier
- type RemoveOp
- type ReplaceOp
- type RootToken
- type Token
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AfterLastIndexToken ¶
type AfterLastIndexToken struct{}
type AfterModifier ¶
type AfterModifier struct{}
type ArrayIndex ¶
func (ArrayIndex) Concrete ¶
func (i ArrayIndex) Concrete() (int, error)
type ArrayInsertion ¶
func (ArrayInsertion) Concrete ¶
func (i ArrayInsertion) Concrete() (ArrayInsertionIndex, error)
type ArrayInsertionIndex ¶
type ArrayInsertionIndex struct {
// contains filtered or unexported fields
}
func (ArrayInsertionIndex) Update ¶
func (i ArrayInsertionIndex) Update(array []interface{}, obj interface{}) []interface{}
type BeforeModifier ¶
type BeforeModifier struct{}
type DescriptiveOp ¶
func (DescriptiveOp) Apply ¶
func (op DescriptiveOp) Apply(doc interface{}) (interface{}, error)
type IndexToken ¶
type MatchingIndexToken ¶
type NextModifier ¶
type NextModifier struct{}
type OpDefinition ¶
type OpDefinition struct { Type string `json:",omitempty"` Path *string `json:",omitempty"` Value *interface{} `json:",omitempty"` Error *string `json:",omitempty"` }
OpDefinition struct is useful for JSON and YAML unmarshaling
type OpMissingIndexErr ¶
type OpMissingIndexErr struct { Idx int Obj []interface{} }
func (OpMissingIndexErr) Error ¶
func (e OpMissingIndexErr) Error() string
type Ops ¶
type Ops []Op
func NewOpsFromDefinitions ¶
func NewOpsFromDefinitions(opDefs []OpDefinition) (Ops, error)
type Pointer ¶
type Pointer struct {
// contains filtered or unexported fields
}
More or less based on https://tools.ietf.org/html/rfc6901
func NewPointer ¶
func NewPointerFromString ¶
func (*Pointer) UnmarshalFlag ¶
UnmarshalFlag satisfies go-flags flag interface
type PrevModifier ¶
type PrevModifier struct{}
Click to show internal directories.
Click to hide internal directories.