Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ListActions ¶
func ListActions() utask.NotifyActions
ListActions returns a list of available actions to notify
func ListSendersNames ¶
func ListSendersNames() []string
ListSendersNames returns a list of available senders
func RegisterActions ¶
func RegisterActions(na utask.NotifyActions)
RegisterActions set available actions
func RegisterSender ¶
func RegisterSender(s NotificationSender, name string)
RegisterSender adds a NotificationSender to the pool of available senders
func Send ¶
func Send(p Payload, params utask.NotifyActionsParameters)
Send dispatches a Payload over all registered senders
Types ¶
type NotificationSender ¶
type NotificationSender interface {
Send(p Payload)
}
NotificationSender is an object capable of sending a payload over a notification channel, as determined by its implementation
type TaskStateUpdate ¶
type TaskStateUpdate struct { Title string PublicID string State string TemplateName string RequesterUsername string ResolverUsername *string PotentialResolvers []string StepsDone int StepsTotal int }
TaskStateUpdate holds a digest of data representing a task state change
func (TaskStateUpdate) Fields ¶
func (tsu TaskStateUpdate) Fields() []string
Fields returns a list of formatted fields to qualify a message
func (TaskStateUpdate) Message ¶
func (tsu TaskStateUpdate) Message() string
Message renders a string representation of a TaskStateUpdate
Click to show internal directories.
Click to hide internal directories.