notify

package module
v0.0.0-...-75f61f4 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2024 License: MIT Imports: 1 Imported by: 4

README

go.notify

An abstraction library for notifications. It provides following implementations:

pkg.go.dev GitHub Actions Appveyor Codecov

Installation

$ go get -u github.com/hattya/go.notify

License

go.notify is distributed under the terms of the MIT License.

Credits

The Go gopher was designed by Renne French.

CC BY 3.0

Documentation

Overview

Package notify provides an interface for notifications.

Index

Constants

This section is empty.

Variables

View Source
var ErrEvent = errors.New("notify: unknown event")

Functions

This section is empty.

Types

type Icon

type Icon interface{}

Icon represents an icon. Its value is dependent on each implementation.

type Notifier

type Notifier interface {
	// Close closes the Notifier.
	Close() error

	// Register registers the named event to the Notifier. The keys and values
	// of the opts are dependent on each implementation.
	//
	// Notifier may use the icon for notifications.
	Register(event string, icon Icon, opts map[string]interface{}) error

	// Notify notifies the named event by the specified title and body.
	Notify(event, title, body string) error

	// Sys returns the implementation of the Notifier.
	Sys() interface{}
}

Notifier is an interface for notifications.

Directories

Path Synopsis
Package freedesktop implements the Desktop Notifications Specification version 1.2.
Package freedesktop implements the Desktop Notifications Specification version 1.2.
Package gntp implements the Growl Notification Transport Protocol version 1.0.
Package gntp implements the Growl Notification Transport Protocol version 1.0.
internal
sys
Package windows implements the Windows Notifications.
Package windows implements the Windows Notifications.

Jump to

Keyboard shortcuts

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