rediscache

package
v0.0.0-...-d221b79 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2020 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAllKeys

func GetAllKeys(client *redis.Client) ([]string, *nerr.E)

func MakeRedisCache

func MakeRedisCache(devices []sd.StaticDevice, rooms []sd.StaticRoom, pushCron string, configuration config.Cache) (shared.Cache, *nerr.E)

Types

type RedisCache

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

func (*RedisCache) CheckAndStoreDevice

func (rc *RedisCache) CheckAndStoreDevice(device sd.StaticDevice) (bool, sd.StaticDevice, *nerr.E)

func (*RedisCache) CheckAndStoreRoom

func (rc *RedisCache) CheckAndStoreRoom(room sd.StaticRoom) (bool, sd.StaticRoom, *nerr.E)

func (*RedisCache) GetAllDeviceRecords

func (rc *RedisCache) GetAllDeviceRecords() ([]sd.StaticDevice, *nerr.E)

func (*RedisCache) GetAllRoomRecords

func (rc *RedisCache) GetAllRoomRecords() ([]sd.StaticRoom, *nerr.E)

func (*RedisCache) GetCacheName

func (rc *RedisCache) GetCacheName() string

func (*RedisCache) GetCacheType

func (rc *RedisCache) GetCacheType() string

func (*RedisCache) GetDeviceRecord

func (rc *RedisCache) GetDeviceRecord(deviceID string) (sd.StaticDevice, *nerr.E)

func (*RedisCache) GetRoomRecord

func (rc *RedisCache) GetRoomRecord(roomID string) (sd.StaticRoom, *nerr.E)

func (*RedisCache) NukeRoom

func (rc *RedisCache) NukeRoom(id string) ([]string, *nerr.E)

func (*RedisCache) RemoveDevice

func (rc *RedisCache) RemoveDevice(id string) *nerr.E

func (*RedisCache) RemoveRoom

func (rc *RedisCache) RemoveRoom(id string) *nerr.E

func (*RedisCache) StoreAndForwardEvent

func (rc *RedisCache) StoreAndForwardEvent(event events.Event) (bool, *nerr.E)

func (*RedisCache) StoreDeviceEvent

func (rc *RedisCache) StoreDeviceEvent(toSave sd.State) (bool, sd.StaticDevice, *nerr.E)

Jump to

Keyboard shortcuts

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