Interface RecipientDsnFields.Builder

All Superinterfaces:
Buildable, CopyableBuilder<RecipientDsnFields.Builder,RecipientDsnFields>, SdkBuilder<RecipientDsnFields.Builder,RecipientDsnFields>, SdkPojo
Enclosing class:
RecipientDsnFields

public static interface RecipientDsnFields.Builder extends SdkPojo, CopyableBuilder<RecipientDsnFields.Builder,RecipientDsnFields>
  • Method Details

    • finalRecipient

      RecipientDsnFields.Builder finalRecipient(String finalRecipient)

      The email address that the message was ultimately delivered to. This corresponds to the Final-Recipient in the DSN. If not specified, FinalRecipient is set to the Recipient specified in the BouncedRecipientInfo structure. Either FinalRecipient or the recipient in BouncedRecipientInfo must be a recipient of the original bounced message.

      Do not prepend the FinalRecipient email address with rfc 822;, as described in RFC 3798.

      Parameters:
      finalRecipient - The email address that the message was ultimately delivered to. This corresponds to the Final-Recipient in the DSN. If not specified, FinalRecipient is set to the Recipient specified in the BouncedRecipientInfo structure. Either FinalRecipient or the recipient in BouncedRecipientInfo must be a recipient of the original bounced message.

      Do not prepend the FinalRecipient email address with rfc 822;, as described in RFC 3798.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • action

      The action performed by the reporting mail transfer agent (MTA) as a result of its attempt to deliver the message to the recipient address. This is required by RFC 3464.

      Parameters:
      action - The action performed by the reporting mail transfer agent (MTA) as a result of its attempt to deliver the message to the recipient address. This is required by RFC 3464.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • action

      The action performed by the reporting mail transfer agent (MTA) as a result of its attempt to deliver the message to the recipient address. This is required by RFC 3464.

      Parameters:
      action - The action performed by the reporting mail transfer agent (MTA) as a result of its attempt to deliver the message to the recipient address. This is required by RFC 3464.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • remoteMta

      RecipientDsnFields.Builder remoteMta(String remoteMta)

      The MTA to which the remote MTA attempted to deliver the message, formatted as specified in RFC 3464 (mta-name-type; mta-name). This parameter typically applies only to propagating synchronous bounces.

      Parameters:
      remoteMta - The MTA to which the remote MTA attempted to deliver the message, formatted as specified in RFC 3464 (mta-name-type; mta-name). This parameter typically applies only to propagating synchronous bounces.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • status

      The status code that indicates what went wrong. This is required by RFC 3464.

      Parameters:
      status - The status code that indicates what went wrong. This is required by RFC 3464.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • diagnosticCode

      RecipientDsnFields.Builder diagnosticCode(String diagnosticCode)

      An extended explanation of what went wrong; this is usually an SMTP response. See RFC 3463 for the correct formatting of this parameter.

      Parameters:
      diagnosticCode - An extended explanation of what went wrong; this is usually an SMTP response. See RFC 3463 for the correct formatting of this parameter.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • lastAttemptDate

      RecipientDsnFields.Builder lastAttemptDate(Instant lastAttemptDate)

      The time the final delivery attempt was made, in RFC 822 date-time format.

      Parameters:
      lastAttemptDate - The time the final delivery attempt was made, in RFC 822 date-time format.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • extensionFields

      RecipientDsnFields.Builder extensionFields(Collection<ExtensionField> extensionFields)

      Additional X-headers to include in the DSN.

      Parameters:
      extensionFields - Additional X-headers to include in the DSN.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • extensionFields

      RecipientDsnFields.Builder extensionFields(ExtensionField... extensionFields)

      Additional X-headers to include in the DSN.

      Parameters:
      extensionFields - Additional X-headers to include in the DSN.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • extensionFields

      RecipientDsnFields.Builder extensionFields(Consumer<ExtensionField.Builder>... extensionFields)

      Additional X-headers to include in the DSN.

      This is a convenience method that creates an instance of the ExtensionField.Builder avoiding the need to create one manually via ExtensionField.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to extensionFields(List<ExtensionField>).

      Parameters:
      extensionFields - a consumer that will call methods on ExtensionField.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also: