aemail

package
v1.6.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Email

type Email struct {
	From     string   //Send email
	To       []string //Accept mailbox
	Cc       []string //Set cc
	Bcc      []string //Set Bcc
	Title    string   //Email title
	Text     string   //Email Text
	Html     string   //Email Html
	Password string   //Email password
	Address  string   //Send email address
	Host     string   //Send email host
	FilePath []string //Email attachment path
	Err      error    //Email error
}

Email Email parameter structure

func New

func New(from ...string) *Email

New 创建

func (*Email) Send

func (e *Email) Send() error

Send Email

func (*Email) SendWithTLS added in v1.4.3

func (e *Email) SendWithTLS() error

SendWithTLS sends an email over tls with an optional TLS config.

func (*Email) SetAddress

func (e *Email) SetAddress(address string) *Email

SetAddress Set Address

func (*Email) SetFilePath

func (e *Email) SetFilePath(filePath []string) *Email

SetFilePath Set Email attachment path

func (*Email) SetFrom

func (e *Email) SetFrom(from string) *Email

SetFrom Set Send email

func (*Email) SetHost

func (e *Email) SetHost(host string) *Email

SetHost Set Host

func (*Email) SetHtml

func (e *Email) SetHtml(html string) *Email

SetHtml Set Html

func (*Email) SetPassword

func (e *Email) SetPassword(password string) *Email

SetPassword Set Password

func (*Email) SetText

func (e *Email) SetText(text string) *Email

SetText Set Text

func (*Email) SetTitle

func (e *Email) SetTitle(title string) *Email

SetTitle Set Title

func (*Email) SetTo

func (e *Email) SetTo(to []string) *Email

SetTo Set To

Jump to

Keyboard shortcuts

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