Documentation ¶
Index ¶
- Variables
- type RedisStorage
- func (s *RedisStorage) GetDeviceConnectSession(dev_id string) (string, error)
- func (s *RedisStorage) GetHeartbeatAt(mdl_id string) (time.Time, error)
- func (s *RedisStorage) GetModuleSession(mdl_id string) (int64, error)
- func (s *RedisStorage) Heartbeat(mdl_id string) error
- func (s *RedisStorage) IsDeviceConnectSession(dev_id string, sess string) error
- func (s *RedisStorage) SetDeviceConnectSession(dev_id string, sess string) error
- func (s *RedisStorage) SetModuleSession(mdl_id string, sess int64) error
- func (s *RedisStorage) UnsetDeviceConnectSession(dev_id string, sess string) error
- func (s *RedisStorage) UnsetModuleSession(mdl_id string) error
- type RedisStorageFactory
- type RedisStorageOption
- type Storage
- type StorageFactory
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type RedisStorage ¶
type RedisStorage struct {
// contains filtered or unexported fields
}
func (*RedisStorage) GetDeviceConnectSession ¶
func (s *RedisStorage) GetDeviceConnectSession(dev_id string) (string, error)
func (*RedisStorage) GetHeartbeatAt ¶
func (s *RedisStorage) GetHeartbeatAt(mdl_id string) (time.Time, error)
func (*RedisStorage) GetModuleSession ¶
func (s *RedisStorage) GetModuleSession(mdl_id string) (int64, error)
func (*RedisStorage) Heartbeat ¶
func (s *RedisStorage) Heartbeat(mdl_id string) error
func (*RedisStorage) IsDeviceConnectSession ¶
func (s *RedisStorage) IsDeviceConnectSession(dev_id string, sess string) error
func (*RedisStorage) SetDeviceConnectSession ¶
func (s *RedisStorage) SetDeviceConnectSession(dev_id string, sess string) error
func (*RedisStorage) SetModuleSession ¶
func (s *RedisStorage) SetModuleSession(mdl_id string, sess int64) error
func (*RedisStorage) UnsetDeviceConnectSession ¶
func (s *RedisStorage) UnsetDeviceConnectSession(dev_id string, sess string) error
func (*RedisStorage) UnsetModuleSession ¶ added in v1.1.22
func (s *RedisStorage) UnsetModuleSession(mdl_id string) error
type RedisStorageFactory ¶
type RedisStorageFactory struct{}
func (*RedisStorageFactory) New ¶
func (f *RedisStorageFactory) New(args ...interface{}) (Storage, error)
type RedisStorageOption ¶
type Storage ¶
type Storage interface { Heartbeat(mdl_id string) error GetHeartbeatAt(mdl_id string) (time.Time, error) SetModuleSession(mdl_id string, sess int64) error UnsetModuleSession(mdl_id string) error GetModuleSession(mdl_id string) (int64, error) SetDeviceConnectSession(dev_id string, sess string) error UnsetDeviceConnectSession(dev_id string, sess string) error GetDeviceConnectSession(dev_id string) (string, error) }
func NewStorage ¶
type StorageFactory ¶
Click to show internal directories.
Click to hide internal directories.