Documentation ¶
Index ¶
Constants ¶
View Source
const ( ReadMode = "r" WriteMode = "w" PersistMode = "+" )
Variables ¶
View Source
var ( // ErrMissingKeyArg is thrown when the client did not send the key argument for the command ErrMissingKeyArg = errors.New("missing key argument") // ErrMissingValueArg is thrown when the client did not send the value argument for the command ErrMissingValueArg = errors.New("missing value argument") // ErrMissingKeyValueArg is thrown when the client did not send both the key and value arguments for the command ErrMissingKeyValueArg = errors.New("missing key/value arguments") // ErrInvalidArgLength is thrown when the client provides missing arguments or does not satisfy the amount of required args for the command ErrInvalidArgLength = errors.New("missing arguments") // ErrCommandDoesNotExist is thrown when the command does not exists in the command package ErrCommandDoesNotExist = errors.New("command does not exists") // ErrInternalError is thrown when an error on the server side has occured ErrInternalError = errors.New("internal error") )
Functions ¶
This section is empty.
Types ¶
type Op ¶ added in v0.4.3
type Op int
Op represents the command operation code
const ( // SET inserts a new entry into the database SET Op = iota // SETEX inserts a new expirable entry into the database SETEX // GET returns the data in the database with the matching key GET // DEL remove an entry in the database with the matching key DEL // KEYS displays all the saved keys in the database KEYS // FLUSHALL delete all keys FLUSHALL // INFO displays the current status of the server (memory allocs, connected clients, uptime, etc.) INFO // Pings the server PING )
func (Op) Description ¶ added in v0.20.3
Description is the command operation description
Click to show internal directories.
Click to hide internal directories.