channel

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2023 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Channel

type Channel interface {
	GetName() string
	IsEnable() bool
	Send(r report.Report) error
}

func GetChannels

func GetChannels(config conf.Config, formatter message.Formatter) []Channel

type FileChannel

type FileChannel struct {
	Opts             config.FileChannelOpts
	MessageFormatter message.Formatter
}

func (*FileChannel) GetName

func (ch *FileChannel) GetName() string

func (*FileChannel) IsEnable

func (ch *FileChannel) IsEnable() bool

func (*FileChannel) Send

func (ch *FileChannel) Send(r report.Report) error

type NotifySendChannel

type NotifySendChannel struct {
	Opts             config.NotifySendChannelOpts
	MessageFormatter message.Formatter
}

func (*NotifySendChannel) GetName

func (ch *NotifySendChannel) GetName() string

func (*NotifySendChannel) IsEnable

func (ch *NotifySendChannel) IsEnable() bool

func (*NotifySendChannel) Send

func (ch *NotifySendChannel) Send(r report.Report) error

type SmtpChannel

type SmtpChannel struct {
	Opts             config.SmtpChannelOpts
	MessageFormatter message.Formatter
}

func (*SmtpChannel) GetName

func (ch *SmtpChannel) GetName() string

func (*SmtpChannel) IsEnable

func (ch *SmtpChannel) IsEnable() bool

func (*SmtpChannel) Send

func (ch *SmtpChannel) Send(r report.Report) error

type TelegramBotChannel

type TelegramBotChannel struct {
	Opts             config.TelegramBotChannelOpts
	MessageFormatter message.Formatter
}

func (*TelegramBotChannel) GetName

func (ch *TelegramBotChannel) GetName() string

func (*TelegramBotChannel) IsEnable

func (ch *TelegramBotChannel) IsEnable() bool

func (*TelegramBotChannel) Send

func (ch *TelegramBotChannel) Send(r report.Report) error

Jump to

Keyboard shortcuts

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