Documentation
¶
Index ¶
- type RawEventRowUint
- type StorageMemory
- func (s StorageMemory) AddEventRow(payload payload.Payload) bool
- func (s StorageMemory) DeleteAllEventRows() int64
- func (s StorageMemory) DeleteEventRows(ids []int) int64
- func (s StorageMemory) GetAllEventRows() []storageiface.EventRow
- func (s StorageMemory) GetEventRowsWithinRange(eventRange int) []storageiface.EventRow
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RawEventRowUint ¶
type RawEventRowUint struct {
// contains filtered or unexported fields
}
type StorageMemory ¶
func Init ¶
func Init() *StorageMemory
func (StorageMemory) AddEventRow ¶
func (s StorageMemory) AddEventRow(payload payload.Payload) bool
AddEventRow adds a new event to the database.
As entries are not auto-incremeneting the id is incremented manually which means inserts are capped at a maximum of 4294967295. If the Index hits this value it rolls over back to 0.
Due to (https://github.com/hashicorp/go-memdb/issues/7) events will get overwritten once past this point as Uniqueness is not observed.
func (StorageMemory) DeleteAllEventRows ¶
func (s StorageMemory) DeleteAllEventRows() int64
DeleteAllEventRows removes all rows within the memory store
func (StorageMemory) DeleteEventRows ¶
func (s StorageMemory) DeleteEventRows(ids []int) int64
DeleteEventRows removes all rows with matching identifiers
func (StorageMemory) GetAllEventRows ¶
func (s StorageMemory) GetAllEventRows() []storageiface.EventRow
GetAllEventRows returns all rows within the memory store
func (StorageMemory) GetEventRowsWithinRange ¶
func (s StorageMemory) GetEventRowsWithinRange(eventRange int) []storageiface.EventRow
GetEventRowsWithinRange returns all available events or a maximal slice
Click to show internal directories.
Click to hide internal directories.