send

package
v2.0.91 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultTpl = "<b>%s</b> \n\n# Time: %s\n# Content: %s\n# Message: %s \n%s"
View Source
const (
	Name = "MultiSend"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Message added in v2.0.53

type Message struct {
	Template string `json:"template"`
	SrvName  string `json:"srv_name"`
	User     string `json:"user_id"`
	Title    string `json:"title"`
	Content  string `json:"content"`
	Time     string `json:"time"`
	Msg      string `json:"msg"`
}

func (*Message) Format added in v2.0.53

func (msg *Message) Format(level string) string

func (*Message) GetContent added in v2.0.54

func (msg *Message) GetContent() string

func (*Message) GetMsg added in v2.0.54

func (msg *Message) GetMsg() string

func (*Message) GetTime added in v2.0.54

func (msg *Message) GetTime() string

func (*Message) GetTitle added in v2.0.54

func (msg *Message) GetTitle(level string) string

func (*Message) GetUser added in v2.0.54

func (msg *Message) GetUser() string

type MultiSend

type MultiSend[T send.ISendMsg] struct {
	// contains filtered or unexported fields
}

func NewMulti

func NewMulti(c ...send.ISender[send.ISendMsg]) *MultiSend[send.ISendMsg]

func (*MultiSend[T]) Error

func (t *MultiSend[T]) Error(ctx context.Context, msg T) (err error)

func (*MultiSend[T]) Info

func (t *MultiSend[T]) Info(ctx context.Context, msg T) (err error)

func (*MultiSend[T]) String

func (t *MultiSend[T]) String() string

func (*MultiSend[T]) Warn

func (t *MultiSend[T]) Warn(ctx context.Context, msg T) (err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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