-
A UUID for the mail.
Declaration
Swift
public let uuid: String -
Subject of the
Mail. Defaults to none.Declaration
Swift
public let subject: String -
Text of the
Mail. Defaults to none.Declaration
Swift
public let text: String -
Array of
Attachments for theMail. If theMailhas multipleAttachments that are alternatives to plain text, the last one will be used as the alternative (all theAttachmentswill still be sent). Defaults to none.Declaration
Swift
public let attachments: [Attachment] -
Attachment that is an alternative to plain text.
Declaration
Swift
public let alternative: Attachment? -
Additional headers for the
Mail. Header keys are capitalized and duplicate keys will overwrite each other. Defaults to none. The following will be ignored: CONTENT-TYPE, CONTENT-DISPOSITION, CONTENT-TRANSFER-ENCODING.Declaration
Swift
public let additionalHeaders: [String : String] -
Declaration
Swift
public var id: String { get } -
Hostname from the email address.
Declaration
Swift
public var hostname: String { get } -
Initializes a
Mailobject.Declaration
Swift
public init(from: User, to: [User], cc: [User] = [], bcc: [User] = [], subject: String = "", text: String = "", attachments: [Attachment] = [], additionalHeaders: [String: String] = [:])Parameters
fromThe
Userthat theMailwill be sent from.toArray of
Users to send theMailto.ccArray of
Users to cc. Defaults to none.bccArray of
Users to bcc. Defaults to none.subjectSubject of the
Mail. Defaults to none.textText of the
Mail. Defaults to none.attachmentsArray of
Attachments for theMail. If theMailhas multipleAttachments that are alternatives to plain text, the last one will be used as the alternative (all theAttachmentswill still be sent). Defaults to none.additionalHeadersAdditional headers for the
Mail. Header keys are capitalized and duplicate keys will overwrite each other. Defaults to none. The following will be ignored: CONTENT-TYPE, CONTENT-DISPOSITION, CONTENT-TRANSFER-ENCODING. -
Represents a sender or receiver of an email.
See moreDeclaration
Swift
public struct User
View on GitHub
Mail Structure Reference