Documentation ¶
Index ¶
- type August
- func (a *August) Config(k AugustConfigOption, v interface{})
- func (a *August) GetStore(name string) (*AugustStore, error)
- func (a *August) Marshal(input interface{}) ([]byte, error)
- func (a *August) Register(name string, store interface{})
- func (a *August) Run() error
- func (a *August) SetEventFunc(f AugustEventFunc)
- func (a *August) Unmarshal(input []byte, output interface{}) error
- func (a *August) Verbose()
- type AugustConfig
- type AugustConfigOption
- type AugustEventFunc
- type AugustStore
- func (as *AugustStore) Delete(id string) error
- func (as *AugustStore) Get(id string) (interface{}, error)
- func (as *AugustStore) GetAll() (map[string]interface{}, error)
- func (as *AugustStore) GetIds() []string
- func (as *AugustStore) New(val interface{}) (string, error)
- func (as *AugustStore) Purge() error
- func (as *AugustStore) Set(id string, val interface{}) error
- func (as *AugustStore) ValidateId(id string) error
- type AugustStoreDataset
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type August ¶
type August struct {
// contains filtered or unexported fields
}
func (*August) Config ¶
func (a *August) Config(k AugustConfigOption, v interface{})
Set a config option.
func (*August) GetStore ¶
func (a *August) GetStore(name string) (*AugustStore, error)
Get a store by name.
func (*August) SetEventFunc ¶
func (a *August) SetEventFunc(f AugustEventFunc)
type AugustConfig ¶
type AugustConfig struct { StorageDir string // Storage directory for August to keep files. Verbose bool // Enable logging. Format string FSNotify bool }
AugustConfig stores basic configuration for August.
type AugustConfigOption ¶
type AugustConfigOption string
const ( // Storage directory for August to keep files. Config_StorageDir AugustConfigOption = "StorageDir" Config_Verbose AugustConfigOption = "Verbose" Config_Format AugustConfigOption = "Format" Config_FSNotify AugustConfigOption = "FSNotify" )
func (AugustConfigOption) String ¶
func (c AugustConfigOption) String() string
type AugustEventFunc ¶
type AugustEventFunc func(event, store, id string)
type AugustStore ¶
type AugustStore struct {
// contains filtered or unexported fields
}
an agust store represents individual data stores (folders) within the storage directory
func (*AugustStore) Delete ¶
func (as *AugustStore) Delete(id string) error
Delete removes a value from the store by id.
func (*AugustStore) Get ¶
func (as *AugustStore) Get(id string) (interface{}, error)
Get retrieves a value from the store by id.
func (*AugustStore) GetAll ¶
func (as *AugustStore) GetAll() (map[string]interface{}, error)
GetAll returns all values in the store.
func (*AugustStore) New ¶
func (as *AugustStore) New(val interface{}) (string, error)
New create a new value in the store, generating an ID for you and returning that ID.
func (*AugustStore) Purge ¶
func (as *AugustStore) Purge() error
Purge will delete all of the data in a store.
func (*AugustStore) Set ¶
func (as *AugustStore) Set(id string, val interface{}) error
Set stores a value in the store by id. Updating an existing value if it exists.
func (*AugustStore) ValidateId ¶
func (as *AugustStore) ValidateId(id string) error
type AugustStoreDataset ¶
type AugustStoreDataset struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.