email

package
v0.0.0-...-b019d3a Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Notificator

type Notificator struct {
	Sender Sender
	Groups map[string][]string
}

func NewNotificator

func NewNotificator(smtp, login, password string) *Notificator

func (*Notificator) AddGroup

func (n *Notificator) AddGroup(name string, addresses []string)

func (Notificator) Send

func (n Notificator) Send(group, sub, body string) error

type Sender

type Sender struct {
	SMTPServer string
	Login      string
	Password   string
}

func (Sender) Next

func (s Sender) Next(fromServer []byte, more bool) ([]byte, error)

func (Sender) SendMail

func (s Sender) SendMail(to []string, subj, body string) error

func (Sender) Start

func (s Sender) Start(_ *smtp.ServerInfo) (string, []byte, error)

Jump to

Keyboard shortcuts

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