Documentation ¶
Index ¶
- type MenuStorageService
- func (ms *MenuStorageService) Close() error
- func (ms *MenuStorageService) EnsureDbDir() error
- func (ms *MenuStorageService) GetPersister(ctx context.Context) (*persist.Persister, error)
- func (ms *MenuStorageService) GetResource(ctx context.Context) (resource.Resource, error)
- func (ms *MenuStorageService) GetStateStore(ctx context.Context) (db.Db, error)
- func (ms *MenuStorageService) GetUserdataDb(ctx context.Context) (db.Db, error)
- type PrefixDb
- type SimpleStorageProvider
- type Storage
- type StorageProvider
- type StorageService
- type SubPrefixDb
- type ThreadGdbmDb
- func (tdb *ThreadGdbmDb) Close() error
- func (tdb *ThreadGdbmDb) Connect(ctx context.Context, connStr string) error
- func (tdb *ThreadGdbmDb) Dump(ctx context.Context, key []byte) (*db.Dumper, error)
- func (tdb *ThreadGdbmDb) Get(ctx context.Context, key []byte) ([]byte, error)
- func (tdb *ThreadGdbmDb) Prefix() uint8
- func (tdb *ThreadGdbmDb) Put(ctx context.Context, key []byte, val []byte) error
- func (tdb *ThreadGdbmDb) Safe() bool
- func (tdb *ThreadGdbmDb) SetLanguage(lng *lang.Language)
- func (tdb *ThreadGdbmDb) SetLock(typ uint8, locked bool) error
- func (tdb *ThreadGdbmDb) SetPrefix(pfx uint8)
- func (tdb *ThreadGdbmDb) SetSession(sessionId string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MenuStorageService ¶
type MenuStorageService struct {
// contains filtered or unexported fields
}
func NewMenuStorageService ¶
func NewMenuStorageService(dbDir string, resourceDir string) *MenuStorageService
func (*MenuStorageService) Close ¶
func (ms *MenuStorageService) Close() error
func (*MenuStorageService) EnsureDbDir ¶
func (ms *MenuStorageService) EnsureDbDir() error
func (*MenuStorageService) GetPersister ¶
func (*MenuStorageService) GetResource ¶
func (*MenuStorageService) GetStateStore ¶
func (*MenuStorageService) GetUserdataDb ¶
type PrefixDb ¶
type PrefixDb interface { Get(ctx context.Context, key []byte) ([]byte, error) Put(ctx context.Context, key []byte, val []byte) error }
PrefixDb interface abstracts the database operations.
type SimpleStorageProvider ¶
type SimpleStorageProvider struct {
*Storage
}
func (*SimpleStorageProvider) Close ¶
func (p *SimpleStorageProvider) Close() error
type StorageProvider ¶
type StorageProvider interface { Get(sessionId string) (*Storage, error) Put(sessionId string, storage *Storage) error Close() error }
func NewSimpleStorageProvider ¶
func NewSimpleStorageProvider(stateStore db.Db, userdataStore db.Db) StorageProvider
type StorageService ¶
type SubPrefixDb ¶
type SubPrefixDb struct {
// contains filtered or unexported fields
}
func NewSubPrefixDb ¶
func NewSubPrefixDb(store db.Db, pfx []byte) *SubPrefixDb
type ThreadGdbmDb ¶
type ThreadGdbmDb struct {
// contains filtered or unexported fields
}
func NewThreadGdbmDb ¶
func NewThreadGdbmDb() *ThreadGdbmDb
func (*ThreadGdbmDb) Close ¶
func (tdb *ThreadGdbmDb) Close() error
func (*ThreadGdbmDb) Connect ¶
func (tdb *ThreadGdbmDb) Connect(ctx context.Context, connStr string) error
func (*ThreadGdbmDb) Prefix ¶
func (tdb *ThreadGdbmDb) Prefix() uint8
func (*ThreadGdbmDb) Safe ¶
func (tdb *ThreadGdbmDb) Safe() bool
func (*ThreadGdbmDb) SetLanguage ¶
func (tdb *ThreadGdbmDb) SetLanguage(lng *lang.Language)
func (*ThreadGdbmDb) SetPrefix ¶
func (tdb *ThreadGdbmDb) SetPrefix(pfx uint8)
func (*ThreadGdbmDb) SetSession ¶
func (tdb *ThreadGdbmDb) SetSession(sessionId string)
Click to show internal directories.
Click to hide internal directories.