DataProperty

public struct DataProperty

Properties when the attachment is some raw data.

  • Data content.

    Declaration

    Swift

    public let data: Data
  • MIME type of the data.

    Declaration

    Swift

    public let mime: String
  • File name which will be presented in the mail.

    Declaration

    Swift

    public let name: String
  • Whether the data could be inline or not. When set to true, the attachment “Content-Disposition” header will be inline, otherwise it will be attachment.

    Declaration

    Swift

    public let inline: Bool
  • Initilize a file property.

    Declaration

    Swift

    public init(data: Data, mime: String, name: String, inline: Bool)

    Parameters

    data

    Data content.

    mime

    MIME type of the file.

    name

    File name which will be presented in the mail.

    inline

    Whether the file could be inline or not. When set to true, the attachment “Content-Disposition” header will be inline, otherwise it will be attachment.