Documentation ¶
Overview ¶
Package memcache implements a memcache driver for github.com/bradfitz/gomemcache/memcache
Index ¶
- Variables
- type Memcache
- func (m *Memcache) Add(key string, val interface{}, exp time.Duration) error
- func (m *Memcache) Client() *memcache.Client
- func (m *Memcache) Decrement(key string, delta uint64) error
- func (m *Memcache) Del(key string) error
- func (m *Memcache) Exists(key string) bool
- func (m *Memcache) Flush() error
- func (m *Memcache) Get(key string, dstVal interface{}) error
- func (m *Memcache) Increment(key string, delta uint64) error
- func (m *Memcache) Replace(key string, val interface{}, exp time.Duration) error
- func (m *Memcache) Set(key string, value interface{}, exp time.Duration) error
- func (m *Memcache) Touch(key string, exp time.Duration) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Codec is the codec used to marshal/unmarshal interfaces into the byte slices required by the Memcache client Codec codec.Codec )
Functions ¶
This section is empty.
Types ¶
type Memcache ¶
type Memcache struct {
// contains filtered or unexported fields
}
Memcache is a struct which implements cache.Cache interface and connects to a Memcache server
func (*Memcache) Add ¶
Add writes the given item, if no value already exists for its key. ErrNotStored is returned if that condition is not met.
func (*Memcache) Client ¶
Client returns the underlying Memcache client to enable usage of it's more powerful feature-set
func (*Memcache) Replace ¶
Replace writes the given item, but only if the server *does* already hold data for this key
Click to show internal directories.
Click to hide internal directories.