Documentation ¶
Overview ¶
Package graphsshortcut handles storing and retrieving shortcuts for graphs.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GraphConfig ¶
type GraphConfig struct { Queries []string `json:"queries"` Formulas []string `json:"formulas"` Keys string `json:"keys"` }
GraphConfig represent the configurations used to populate a single graph.
type GraphsShortcut ¶
type GraphsShortcut struct {
Graphs []GraphConfig `json:"graphs"`
}
GraphsShortcut is a list of GraphConfigs, it is used in the Store interface.
func (GraphsShortcut) GetID ¶
func (s GraphsShortcut) GetID() string
type Store ¶
type Store interface { // InsertShortcut adds the shortcut content into the database. The id of the // shortcut is returned. InsertShortcut(ctx context.Context, shortcut *GraphsShortcut) (string, error) // GetShortcut retrieves parsed graph configs for the given id. GetShortcut(ctx context.Context, id string) (*GraphsShortcut, error) }
Store is an interface for things that persists Graphs Shortcuts.
Directories ¶
Path | Synopsis |
---|---|
Package graphsshortcuttest has common code for tests of implementations of graphsshortcut.Store.
|
Package graphsshortcuttest has common code for tests of implementations of graphsshortcut.Store. |
Click to show internal directories.
Click to hide internal directories.