Documentation ¶
Index ¶
- func NewKvOptionsWith(opts ...store.Option) []kv.Option
- type DocumentKvStore
- type DocumentStore
- type Service
- type Store
- func (s *Store) CreateDatabase(ctx context.Context, name string) error
- func (s *Store) GetDatabase(ctx context.Context, name string) (store.Database, error)
- func (s *Store) KvStore() kv.Store
- func (s *Store) ListDatabases(ctx context.Context) ([]store.Database, error)
- func (s *Store) RemoveDatabase(ctx context.Context, name string) error
- func (s *Store) ServiceName() string
- func (s *Store) ServiceType() plugins.ServiceType
- func (s *Store) SetConfig(conf config.Config)
- func (s *Store) SetDocumentCoder(coder document.Coder)
- func (s *Store) SetKeyCoder(coder document.KeyCoder)
- func (s *Store) SetKvStore(kvs kv.Store)
- func (s *Store) Start() error
- func (s *Store) Stop() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DocumentKvStore ¶ added in v1.0.0
type DocumentKvStore interface { DocumentStore KvStore() kv.Store }
DocumentKvStore represents a document key-value store interface.
type DocumentStore ¶ added in v1.0.0
DocumentStore represents a document store interface.
type Service ¶
type Service interface { DocumentStore plugins.Service }
Service represents a document store service interface.
type Store ¶
Store represents a store interface.
func NewStoreWith ¶ added in v0.9.0
NewStoreWith returns a new store with the specified key-value store service.
func (*Store) CreateDatabase ¶
CreateDatabase creates a new database.
func (*Store) GetDatabase ¶
GetDatabase retruns the specified database.
func (*Store) ListDatabases ¶ added in v0.9.0
ListDatabases returns the all databases.
func (*Store) RemoveDatabase ¶
RemoveDatabase removes the specified database.
func (*Store) ServiceName ¶
ServiceName returns the plug-ing service name.
func (*Store) ServiceType ¶
func (s *Store) ServiceType() plugins.ServiceType
ServiceType returns the plug-ing service type.
func (*Store) SetDocumentCoder ¶ added in v0.9.0
SetDocumentCoder sets the document coder.
func (*Store) SetKeyCoder ¶ added in v0.9.0
SetKeyCoder sets the key coder.
func (*Store) SetKvStore ¶ added in v0.9.0
SetKvStore sets the key-value store service.