email

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HtmlMailer

type HtmlMailer struct {
	Mailer
}

func CreateHtmlMailer

func CreateHtmlMailer(c *MailConfig) *HtmlMailer

func (*HtmlMailer) MsgBuilder

func (hm *HtmlMailer) MsgBuilder() *HtmlMsgBuilder

type HtmlMsgBuilder

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

func (*HtmlMsgBuilder) Bcc

func (hmb *HtmlMsgBuilder) Bcc(bcc []string) *HtmlMsgBuilder

func (*HtmlMsgBuilder) Build

func (hmb *HtmlMsgBuilder) Build() (*mail.Msg, error)

func (*HtmlMsgBuilder) Cc

func (hmb *HtmlMsgBuilder) Cc(cc []string) *HtmlMsgBuilder

func (*HtmlMsgBuilder) Data

func (hmb *HtmlMsgBuilder) Data(data any) *HtmlMsgBuilder

func (*HtmlMsgBuilder) HtmlTemplate

func (hmb *HtmlMsgBuilder) HtmlTemplate(template string) *HtmlMsgBuilder

func (*HtmlMsgBuilder) Subject

func (hmb *HtmlMsgBuilder) Subject(subject string) *HtmlMsgBuilder

func (*HtmlMsgBuilder) To

func (hmb *HtmlMsgBuilder) To(to []string) *HtmlMsgBuilder

type MailConfig

type MailConfig struct {
	Host     string `mapstructure:"host"`
	Port     int    `mapstructure:"port"`
	From     string `mapstructure:"from"`
	Username string `mapstructure:"username"`
	Password string `mapstructure:"password"`
	UseSSL   bool   `mapstructure:"useSSL"`
}

type Mailer

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

func (*Mailer) Send

func (m *Mailer) Send(msg ...*mail.Msg) error

Jump to

Keyboard shortcuts

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