Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DisablePreset ¶
* Disables preset by removing link file from EnabledPresetPath
func EnablePreset ¶
* Enables preset by creating a link from the AvailablePresetPath to the EnabledPresetPath
func GetAvailablePresets ¶
func GetAvailablePresets() []string
* Gets available preset file names from AvailablePresetPath
Types ¶
type Preset ¶
type Preset struct { Name string `json:"name"` Description string `json:"description"` Events []struct { Name string `json:"name"` Description string `json:"description"` PollingTime int64 `json:"pollingTime"` Conditions []struct { Id int `json:"id"` Description string `json:"description"` Function function.Function `json:"function"` ExpectedVal interface{} `json:"expected_val"` } `json:"conditions"` ConditionExp string `json:"condition_exp"` } `json:"events"` Reactions []struct { Name string `json:"name"` Function function.Function `json:"function"` } `json:"reactions"` }
func LoadActivePresets ¶
func LoadActivePresets() []Preset
* Loads active preset files from EnabledPresetPath directory
Click to show internal directories.
Click to hide internal directories.