notify

package
v0.1.12 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2025 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DbusNotifier added in v0.1.4

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

func (*DbusNotifier) Close added in v0.1.4

func (n *DbusNotifier) Close() error

func (*DbusNotifier) Initialize added in v0.1.4

func (n *DbusNotifier) Initialize() error

func (*DbusNotifier) Send added in v0.1.4

func (n *DbusNotifier) Send(resChan chan<- Result, notification Notification)

type Notification added in v0.1.4

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

type NotificationBuilder added in v0.1.4

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

func NewNotificationBuilder added in v0.1.4

func NewNotificationBuilder() *NotificationBuilder

func (*NotificationBuilder) Build added in v0.1.4

func (b *NotificationBuilder) Build() (Notification, error)

func (*NotificationBuilder) SetBodyTemplate added in v0.1.12

func (b *NotificationBuilder) SetBodyTemplate(body string) *NotificationBuilder

Sets the body for the notification, will be treated as template if prayer is set

func (*NotificationBuilder) SetDuration added in v0.1.4

func (b *NotificationBuilder) SetDuration(duration time.Duration) *NotificationBuilder

func (*NotificationBuilder) SetIconName added in v0.1.4

func (b *NotificationBuilder) SetIconName(name string) *NotificationBuilder

TODO: check for icon existence

func (*NotificationBuilder) SetPrayer added in v0.1.12

func (b *NotificationBuilder) SetPrayer(
	calendar *calc.PrayerTimes,
	prayer calc.Prayer,
) *NotificationBuilder

func (*NotificationBuilder) SetTitleTemplate added in v0.1.12

func (b *NotificationBuilder) SetTitleTemplate(title string) *NotificationBuilder

Sets the title for the notification, will be treated as template if prayer is set

type Notifier added in v0.1.4

type Notifier interface {
	Initialize() error
	Send(chan<- Result, Notification)
	Close() error
}

func NewNotifier added in v0.1.4

func NewNotifier() Notifier

type Result

type Result struct {
	Clicked bool
	Error   error
}

Jump to

Keyboard shortcuts

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