Documentation ¶
Index ¶
- type RedisStore
- func (r RedisStore) Find(queryStr string, callback datastore.ResultCallback)
- func (r RedisStore) FindAndUpdate(queryStr string, update interface{}, callback datastore.ResultCallback)
- func (r RedisStore) Remove(queryStr string, callback datastore.NoResultCallback)
- func (r RedisStore) Save(key string, data interface{}, callback datastore.NoResultCallback)
- func (r RedisStore) Update(queryStr string, update interface{}, callback datastore.NoResultCallback)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RedisStore ¶
RedisStore is the datastore backed by redis
func New ¶
func New(host, port, password string) *RedisStore
NewRedis returns a pointer to a new RedisStore instance
func (RedisStore) Find ¶
func (r RedisStore) Find(queryStr string, callback datastore.ResultCallback)
Find finds data in redis and takes a ResultCallback
func (RedisStore) FindAndUpdate ¶
func (r RedisStore) FindAndUpdate(queryStr string, update interface{}, callback datastore.ResultCallback)
Find and update does the same as Update but passes the data to the callback as well
func (RedisStore) Remove ¶
func (r RedisStore) Remove(queryStr string, callback datastore.NoResultCallback)
Remove removes data from redis and takes a NoResultCallback
func (RedisStore) Save ¶
func (r RedisStore) Save(key string, data interface{}, callback datastore.NoResultCallback)
Save saves data in redis and takes a NoResultCallback
func (RedisStore) Update ¶
func (r RedisStore) Update(queryStr string, update interface{}, callback datastore.NoResultCallback)
Update updates a key in redis with a new value
Click to show internal directories.
Click to hide internal directories.