Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Init ¶
func Init(user, password, server string)
thread safe initialization. it only writes content to variable packageInitInstance once and since this variable cannot be accesses by other code outside this file, it is completely thread safe
func SendWithGmail ¶
func SendWithGmail(data *model.Maildata) (json.RawMessage, error)
Types ¶
type ApiGmailer ¶
type ApiGmailer struct {
// contains filtered or unexported fields
}
func NewApiGmailer ¶
func NewApiGmailer() *ApiGmailer
type MailServerConfig ¶
func GetGmailServerConfigInstance ¶
func GetGmailServerConfigInstance(user, password, server string) *MailServerConfig
@deprecated use GetGmailServerConfigInstanceInit() instead
warning: this is a non-thread safe implementation of singleton. use at your own risk knowning variable ioproto access
func GetGmailServerConfigInstanceInit ¶
func GetGmailServerConfigInstanceInit() *MailServerConfig
func GetGmailServerConfigInstanceThreadSafe ¶
func GetGmailServerConfigInstanceThreadSafe(user, password, server string) *MailServerConfig
@deprecated use GetGmailServerConfigInstanceInit() instead
func (*MailServerConfig) SendInsecure ¶
func (c *MailServerConfig) SendInsecure(fromMail, toMail *mail.Address, subject, msg string) error
func (*MailServerConfig) SendWithSSL ¶
func (c *MailServerConfig) SendWithSSL(fromMail, toMail *mail.Address, subject, body string) error
Click to show internal directories.
Click to hide internal directories.