update

package
v1.6.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 26, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Increment     string = "Increment"
	Decrement     string = "Decrement"
	Add           string = "Add"
	AddUnique     string = "AddUnique"
	IncrementSet  string = "IncrementSet"
	IncrementFrom string = "IncrementFrom"
)

Valid operations

Variables

This section is empty.

Functions

func NewUpdateCmd

func NewUpdateCmd(f *cmdutil.Factory, runF func(*UpdateOptions) error) *cobra.Command

NewUpdateCmd creates and returns an update command for index objects

func ValidateOperation

func ValidateOperation(p search.PartialUpdateOperation) error

ValidateOperation checks that the operation is valid

Types

type Object

type Object map[string]interface{}

Object is a map[string]interface{} that can be unmarshalled from a JSON object The object must have an objectID field Each field could be either an `search.PartialUpdateOperation` or a any value

func (*Object) UnmarshalJSON

func (o *Object) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshals a JSON object into an Object

type UpdateOptions

type UpdateOptions struct {
	Config config.IConfig
	IO     *iostreams.IOStreams

	SearchClient func() (*search.Client, error)

	Index             string
	CreateIfNotExists bool
	Wait              bool

	File    string
	Scanner *bufio.Scanner

	ContinueOnError bool
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL