notifier

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2018 License: MIT Imports: 1 Imported by: 2 modules, 3 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NOOPNotifier

type NOOPNotifier struct{}

NOOPNotifier is a notifier that doesn't perform any notifications.

func (*NOOPNotifier) NotifyStatusChange

func (n *NOOPNotifier) NotifyStatusChange(featureName string, status bool, environmentName string) error

NotifyStatusChange doesn't perform any operation and always returns nil.

type Notifier

type Notifier interface {
	// NotifyStatusChange notifies a change in the status of a flag.
	NotifyStatusChange(feature string, status bool, environment string) error
}

Notifier describes a notification sender.

func NewNOOPNotifier

func NewNOOPNotifier() Notifier

NewNOOPNotifier creates a new NOOPNotifier.

func NewSlackNotifier

func NewSlackNotifier(url string) Notifier

NewSlackNotifier creates a new SlackNotifier.

type SlackNotifier

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

SlackNotifier is a notifier that send messages to Slack.

func (*SlackNotifier) NotifyStatusChange

func (n *SlackNotifier) NotifyStatusChange(feature string, status bool, environment string) error

NotifyStatusChange notifies a change in the status of a flag.

Jump to

Keyboard shortcuts

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