Documentation
¶
Index ¶
- Constants
- func NewRuleWrapper(rule C.Rule) C.RuleWrapper
- func RuleNotification(params []string) (text string, interval time.Duration, ok bool)
- type NotifyingRule
- type RuleWrapper
- func (r *RuleWrapper) Hit()
- func (r *RuleWrapper) HitAt() time.Time
- func (r *RuleWrapper) HitCount() uint64
- func (r *RuleWrapper) IsDisabled() bool
- func (r *RuleWrapper) Match(metadata *C.Metadata, helper C.RuleMatchHelper) (bool, string)
- func (r *RuleWrapper) Miss()
- func (r *RuleWrapper) MissAt() time.Time
- func (r *RuleWrapper) MissCount() uint64
- func (r *RuleWrapper) SetDisabled(v bool)
- func (r *RuleWrapper) Unwrap() C.Rule
Constants ¶
View Source
const DefaultNotificationInterval = 300 * time.Second
Variables ¶
This section is empty.
Functions ¶
func NewRuleWrapper ¶
func NewRuleWrapper(rule C.Rule) C.RuleWrapper
Types ¶
type NotifyingRule ¶
type NotifyingRule struct {
C.RuleWrapper
// contains filtered or unexported fields
}
func NewNotifyingRule ¶
func NewNotifyingRule(rule C.RuleWrapper, text string, interval time.Duration, written string) *NotifyingRule
func (*NotifyingRule) NotificationDue ¶
func (r *NotifyingRule) NotificationDue(now time.Time) (string, bool)
func (*NotifyingRule) WrittenLine ¶
func (r *NotifyingRule) WrittenLine() string
type RuleWrapper ¶
func (*RuleWrapper) Hit ¶
func (r *RuleWrapper) Hit()
func (*RuleWrapper) HitAt ¶
func (r *RuleWrapper) HitAt() time.Time
func (*RuleWrapper) HitCount ¶
func (r *RuleWrapper) HitCount() uint64
func (*RuleWrapper) IsDisabled ¶
func (r *RuleWrapper) IsDisabled() bool
func (*RuleWrapper) Match ¶
func (r *RuleWrapper) Match(metadata *C.Metadata, helper C.RuleMatchHelper) (bool, string)
func (*RuleWrapper) Miss ¶
func (r *RuleWrapper) Miss()
func (*RuleWrapper) MissAt ¶
func (r *RuleWrapper) MissAt() time.Time
func (*RuleWrapper) MissCount ¶
func (r *RuleWrapper) MissCount() uint64
func (*RuleWrapper) SetDisabled ¶
func (r *RuleWrapper) SetDisabled(v bool)
func (*RuleWrapper) Unwrap ¶
func (r *RuleWrapper) Unwrap() C.Rule
Click to show internal directories.
Click to hide internal directories.