gmemcached

package
v0.0.0-...-0444a71 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2014 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Bytes

func Bytes(v interface{}) []byte

func Float64

func Float64(v interface{}) (float64, error)

func Int64

func Int64(v interface{}) (int64, error)

func SizeOfBody

func SizeOfBody(b interface{}) int

func String

func String(v interface{}) string

Types

type CommandSession

type CommandSession struct {
	CmdType   CommandType
	ReplyType RespondType
	// contains filtered or unexported fields
}

func (*CommandSession) Error

func (C *CommandSession) Error() string

func (*CommandSession) Item

func (C *CommandSession) Item(key string) map[string]interface{}

func (*CommandSession) ReplyBody

func (C *CommandSession) ReplyBody() string

func (*CommandSession) RequestBody

func (C *CommandSession) RequestBody() string

func (*CommandSession) Values

func (C *CommandSession) Values() map[string]interface{}

type CommandType

type CommandType uint32
const (
	InvalidCommand    CommandType = 0
	StorageCommand    CommandType = 1
	RetrievalCommand  CommandType = 2
	DeletionCommand   CommandType = 3
	IncrDecrCommand   CommandType = 4
	TouchCommand      CommandType = 5
	SlabsCommand      CommandType = 6
	StatisticsCommand CommandType = 7
	DeletedCommand    CommandType = 8
	FlushallCommand   CommandType = 9
	VersionCommand    CommandType = 10
)

type GMConnection

type GMConnection struct {
	// contains filtered or unexported fields
}

func Connect

func Connect(server string, port int) (*GMConnection, error)

func ConnectTimeout

func ConnectTimeout(server string, port int, ct time.Duration, wt time.Duration, rt time.Duration) (*GMConnection, error)

func (*GMConnection) Command

func (G *GMConnection) Command(cmd string, data interface{}, args ...interface{}) (*CommandSession, error)

type ReadStatus

type ReadStatus uint32

type RespondType

type RespondType uint32
const (
	RT_UNKNOW      RespondType = 0
	RT_STORED      RespondType = 1
	RT_NOTSTORED   RespondType = 2
	RT_EXISTS      RespondType = 3
	RT_NOTFOUND    RespondType = 4
	RT_ERROR       RespondType = 5
	RT_CLIENTERROR RespondType = 6
	RT_SERVERERROR RespondType = 7
	RT_DELETED     RespondType = 8
	RT_TOUCHED     RespondType = 9
	RT_OK          RespondType = 10
	RT_BUSY        RespondType = 11
	RT_BADCLASS    RespondType = 12
	RT_NOSPARE     RespondType = 13
	RT_NOTFULL     RespondType = 14
	RT_UNSAFE      RespondType = 15
	RT_SAME        RespondType = 16
	RT_VALUE       RespondType = 17
	RT_NULL        RespondType = 18
)

Jump to

Keyboard shortcuts

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