storm

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 13, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BucketBase      = "BASE"
	BucketTemplates = "TEMPLATES"
	BucketSources   = "DATA_SOURCES"
	BucketEntries   = "ENTRIES"
	BucketScripts   = "SCRIPTS"

	KeySettings = "SETTINGS"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Storm

type Storm struct {
	// contains filtered or unexported fields
}

func New

func New(file string) (*Storm, error)

func (*Storm) AddLog

func (s *Storm) AddLog(e log.Entry) error

func (*Storm) CountEntries

func (s *Storm) CountEntries(id string) (int, error)

func (*Storm) DB

func (s *Storm) DB() *storm.DB

func (*Storm) DeleteEntries

func (s *Storm) DeleteEntries(id string) error

func (*Storm) DeleteEntry

func (s *Storm) DeleteEntry(id string, eid string) error

func (*Storm) DeleteSource

func (s *Storm) DeleteSource(id string) error

func (*Storm) DeleteTemplate

func (s *Storm) DeleteTemplate(id string) error

func (*Storm) GetEntries

func (s *Storm) GetEntries(id string) ([]snd.Entry, error)

func (*Storm) GetEntry

func (s *Storm) GetEntry(id string, eid string) (snd.Entry, error)

func (*Storm) GetLogs

func (s *Storm) GetLogs(hours int) ([]log.Entry, error)

func (*Storm) GetSettings

func (s *Storm) GetSettings() (snd.Settings, error)

func (*Storm) GetSource

func (s *Storm) GetSource(id string) (snd.DataSource, error)

func (*Storm) GetSources

func (s *Storm) GetSources() ([]database.DataSourceEntry, error)

func (*Storm) GetTemplate

func (s *Storm) GetTemplate(id string) (snd.Template, error)

func (*Storm) GetTemplates

func (s *Storm) GetTemplates() ([]database.TemplateEntry, error)

func (*Storm) SaveEntry

func (s *Storm) SaveEntry(id string, entry snd.Entry) error

func (*Storm) SaveSettings

func (s *Storm) SaveSettings(settings snd.Settings) error

func (*Storm) SaveSource

func (s *Storm) SaveSource(ds snd.DataSource) error

func (*Storm) SaveTemplate

func (s *Storm) SaveTemplate(template snd.Template) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL