command

package
v0.0.0-...-3cbc9b2 Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2015 License: MIT Imports: 2 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RemoveTmpDataCommand

type RemoveTmpDataCommand struct {
	Key string `json:"key"` //user
}

This command writes a value to a key.

func NewRemoveTmpDataCommand

func NewRemoveTmpDataCommand(key string) *RemoveTmpDataCommand

Creates a new write command.

func (*RemoveTmpDataCommand) Apply

func (c *RemoveTmpDataCommand) Apply(server raft.Server) (interface{}, error)

Writes a value to a key.

func (*RemoveTmpDataCommand) CommandName

func (c *RemoveTmpDataCommand) CommandName() string

The name of the command in the log.

type SetCommand

type SetCommand struct {
	Key   string `json:"key"`
	Value string `json:"value"`
	Tag   string `json:"tag"`
	Verb  uint32 `json:"verb"`
	Oper  string `json:"oper"` //Operator for template data
}

This command writes a value to a key.

func NewSetCommand

func NewSetCommand(key string, value string, tag string, verb uint32, oper string) *SetCommand

Creates a new write command.

func (*SetCommand) Apply

func (c *SetCommand) Apply(server raft.Server) (interface{}, error)

Writes a value to a key.

func (*SetCommand) CommandName

func (c *SetCommand) CommandName() string

The name of the command in the log.

Jump to

Keyboard shortcuts

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