Documentation ¶
Index ¶
- type Provider
- func (p *Provider) Close() error
- func (p *Provider) GetOpenStores() []storage.Store
- func (p *Provider) GetStoreConfig(name string) (storage.StoreConfiguration, error)
- func (p *Provider) OpenStore(name string) (storage.Store, error)
- func (p *Provider) SetStoreConfig(name string, config storage.StoreConfiguration) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Provider ¶
type Provider struct {
// contains filtered or unexported fields
}
Provider is an IndexedDB implementation of the storage.Provider interface.
func NewProvider ¶
NewProvider instantiates a new IndexedDB provider.
func (*Provider) Close ¶
Close closes all stores created under this store provider. There's nothing to do here, so it always returns nil.
func (*Provider) GetOpenStores ¶
GetOpenStores is currently not implemented (TODO #2528).
func (*Provider) GetStoreConfig ¶
func (p *Provider) GetStoreConfig(name string) (storage.StoreConfiguration, error)
GetStoreConfig gets the current store configuration. TODO (#2948) When checking for the store, look for the underlying database instead of the stores open in memory
in order to comply with the interface docs.
func (*Provider) OpenStore ¶
OpenStore opens a store with the given name and returns a handle. If the store has never been opened before, then it is created.
func (*Provider) SetStoreConfig ¶
func (p *Provider) SetStoreConfig(name string, config storage.StoreConfiguration) error
SetStoreConfig sets the configuration on a store. With the current implementation, this does not need to be called in order to use tags and querying. For consistency with other storage implementations, the store configuration is still stored (but it otherwise serves no purpose).