Class RecipientDsnFields
- java.lang.Object
-
- com.amazonaws.services.simpleemail.model.RecipientDsnFields
-
- All Implemented Interfaces:
Serializable
,Cloneable
public class RecipientDsnFields extends Object implements Serializable, Cloneable
Recipient-related information to include in the Delivery Status Notification (DSN) when an email that Amazon SES receives on your behalf bounces.
For information about receiving email through Amazon SES, see the Amazon SES Developer Guide.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description RecipientDsnFields()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RecipientDsnFields
clone()
boolean
equals(Object obj)
String
getAction()
The action performed by the reporting mail transfer agent (MTA) as a result of its attempt to deliver the message to the recipient address.String
getDiagnosticCode()
An extended explanation of what went wrong; this is usually an SMTP response.List<ExtensionField>
getExtensionFields()
Additional X-headers to include in the DSN.String
getFinalRecipient()
The email address to which the message was ultimately delivered.Date
getLastAttemptDate()
The time the final delivery attempt was made, in RFC 822 date-time format.String
getRemoteMta()
The MTA to which the remote MTA attempted to deliver the message, formatted as specified in RFC 3464 (mta-name-type; mta-name
).String
getStatus()
The status code that indicates what went wrong.int
hashCode()
void
setAction(DsnAction 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.void
setAction(String 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.void
setDiagnosticCode(String diagnosticCode)
An extended explanation of what went wrong; this is usually an SMTP response.void
setExtensionFields(Collection<ExtensionField> extensionFields)
Additional X-headers to include in the DSN.void
setFinalRecipient(String finalRecipient)
The email address to which the message was ultimately delivered.void
setLastAttemptDate(Date lastAttemptDate)
The time the final delivery attempt was made, in RFC 822 date-time format.void
setRemoteMta(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
).void
setStatus(String status)
The status code that indicates what went wrong.String
toString()
Returns a string representation of this object; useful for testing and debugging.RecipientDsnFields
withAction(DsnAction 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.RecipientDsnFields
withAction(String 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.RecipientDsnFields
withDiagnosticCode(String diagnosticCode)
An extended explanation of what went wrong; this is usually an SMTP response.RecipientDsnFields
withExtensionFields(ExtensionField... extensionFields)
Additional X-headers to include in the DSN.RecipientDsnFields
withExtensionFields(Collection<ExtensionField> extensionFields)
Additional X-headers to include in the DSN.RecipientDsnFields
withFinalRecipient(String finalRecipient)
The email address to which the message was ultimately delivered.RecipientDsnFields
withLastAttemptDate(Date lastAttemptDate)
The time the final delivery attempt was made, in RFC 822 date-time format.RecipientDsnFields
withRemoteMta(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
).RecipientDsnFields
withStatus(String status)
The status code that indicates what went wrong.
-
-
-
Method Detail
-
setFinalRecipient
public void setFinalRecipient(String finalRecipient)
The email address to which the message was ultimately delivered. This corresponds to the
Final-Recipient
in the DSN. If not specified,FinalRecipient
will be set to theRecipient
specified in theBouncedRecipientInfo
structure. EitherFinalRecipient
or the recipient inBouncedRecipientInfo
must be a recipient of the original bounced message.Do not prepend the FinalRecipient
email address withrfc 822;
, as described in RFC 3798.- Parameters:
finalRecipient
- The email address to which the message was ultimately delivered. This corresponds to theFinal-Recipient
in the DSN. If not specified,FinalRecipient
will be set to theRecipient
specified in theBouncedRecipientInfo
structure. EitherFinalRecipient
or the recipient inBouncedRecipientInfo
must be a recipient of the original bounced message.Do not prepend the FinalRecipient
email address withrfc 822;
, as described in RFC 3798.
-
getFinalRecipient
public String getFinalRecipient()
The email address to which the message was ultimately delivered. This corresponds to the
Final-Recipient
in the DSN. If not specified,FinalRecipient
will be set to theRecipient
specified in theBouncedRecipientInfo
structure. EitherFinalRecipient
or the recipient inBouncedRecipientInfo
must be a recipient of the original bounced message.Do not prepend the FinalRecipient
email address withrfc 822;
, as described in RFC 3798.- Returns:
- The email address to which the message was ultimately delivered.
This corresponds to the
Final-Recipient
in the DSN. If not specified,FinalRecipient
will be set to theRecipient
specified in theBouncedRecipientInfo
structure. EitherFinalRecipient
or the recipient inBouncedRecipientInfo
must be a recipient of the original bounced message.Do not prepend the FinalRecipient
email address withrfc 822;
, as described in RFC 3798.
-
withFinalRecipient
public RecipientDsnFields withFinalRecipient(String finalRecipient)
The email address to which the message was ultimately delivered. This corresponds to the
Final-Recipient
in the DSN. If not specified,FinalRecipient
will be set to theRecipient
specified in theBouncedRecipientInfo
structure. EitherFinalRecipient
or the recipient inBouncedRecipientInfo
must be a recipient of the original bounced message.Do not prepend the FinalRecipient
email address withrfc 822;
, as described in RFC 3798.- Parameters:
finalRecipient
- The email address to which the message was ultimately delivered. This corresponds to theFinal-Recipient
in the DSN. If not specified,FinalRecipient
will be set to theRecipient
specified in theBouncedRecipientInfo
structure. EitherFinalRecipient
or the recipient inBouncedRecipientInfo
must be a recipient of the original bounced message.Do not prepend the FinalRecipient
email address withrfc 822;
, as described in RFC 3798.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setAction
public void setAction(String 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.
-
getAction
public String getAction()
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.
-
withAction
public RecipientDsnFields withAction(String 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:
DsnAction
-
setAction
public void setAction(DsnAction 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.
-
withAction
public RecipientDsnFields withAction(DsnAction 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:
DsnAction
-
setRemoteMta
public void setRemoteMta(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.
-
getRemoteMta
public String getRemoteMta()
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:
- 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.
-
withRemoteMta
public RecipientDsnFields withRemoteMta(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.
-
setStatus
public void setStatus(String 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.
-
getStatus
public String getStatus()
The status code that indicates what went wrong. This is required by RFC 3464.
- Returns:
- The status code that indicates what went wrong. This is required by RFC 3464.
-
withStatus
public RecipientDsnFields withStatus(String 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.
-
setDiagnosticCode
public void setDiagnosticCode(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.
-
getDiagnosticCode
public String getDiagnosticCode()
An extended explanation of what went wrong; this is usually an SMTP response. See RFC 3463 for the correct formatting of this parameter.
- Returns:
- An extended explanation of what went wrong; this is usually an SMTP response. See RFC 3463 for the correct formatting of this parameter.
-
withDiagnosticCode
public RecipientDsnFields withDiagnosticCode(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.
-
setLastAttemptDate
public void setLastAttemptDate(Date 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.
-
getLastAttemptDate
public Date getLastAttemptDate()
The time the final delivery attempt was made, in RFC 822 date-time format.
- Returns:
- The time the final delivery attempt was made, in RFC 822 date-time format.
-
withLastAttemptDate
public RecipientDsnFields withLastAttemptDate(Date 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.
-
getExtensionFields
public List<ExtensionField> getExtensionFields()
Additional X-headers to include in the DSN.
- Returns:
- Additional X-headers to include in the DSN.
-
setExtensionFields
public void setExtensionFields(Collection<ExtensionField> extensionFields)
Additional X-headers to include in the DSN.
- Parameters:
extensionFields
- Additional X-headers to include in the DSN.
-
withExtensionFields
public RecipientDsnFields withExtensionFields(ExtensionField... extensionFields)
Additional X-headers to include in the DSN.
NOTE: This method appends the values to the existing list (if any). Use
setExtensionFields(java.util.Collection)
orwithExtensionFields(java.util.Collection)
if you want to override the existing values.- 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.
-
withExtensionFields
public RecipientDsnFields withExtensionFields(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.
-
toString
public String toString()
Returns a string representation of this object; useful for testing and debugging.- Overrides:
toString
in classObject
- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
clone
public RecipientDsnFields clone()
-
-