Documentation ¶
Index ¶
- func All(item Item) ([][]byte, error)
- func CheckSlugForDuplicate(slug string) (string, error)
- func Close()
- func ContentAll(namespace string) [][]byte
- func Delete(item Item) error
- func Get(item Item) ([]byte, error)
- func NextSequence(item BucketItem) (uint64, error)
- func Query(namespace string, opts QueryOptions) (int, [][]byte)
- func RemoveIndex(slug string) error
- func Set(item Item) error
- func SetIndex(item KeyValue) error
- func Sort(items Items) error
- func Start(dataDir string, contentTypes []string)
- func SystemInitComplete() bool
- type BucketItem
- type Item
- type Items
- type KeyValue
- type QueryOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckSlugForDuplicate ¶
func Close ¶
func Close()
Close exports the abillity to close our db file. Should be called with defer after call to Init() from the same place.
func ContentAll ¶
ContentAll retrives all items from the database within the provided namespace
func NextSequence ¶
func NextSequence(item BucketItem) (uint64, error)
func Query ¶
func Query(namespace string, opts QueryOptions) (int, [][]byte)
Query retrieves a set of content from the db based on options and returns the total number of content in the namespace and the content
func RemoveIndex ¶
func SystemInitComplete ¶
func SystemInitComplete() bool
SystemInitComplete checks if there is at least 1 admin user in the db which would indicate that the system has been configured to the minimum required.
Types ¶
type BucketItem ¶
type BucketItem interface {
Bucket() string
}
type Item ¶
type Item interface { BucketItem KeyValue }
type Items ¶
type Items interface { BucketItem KeyValues() []KeyValue }
type QueryOptions ¶
QueryOptions holds options for a query
Source Files ¶
Click to show internal directories.
Click to hide internal directories.