public class ReceiptRule extends Object implements Serializable, Cloneable
Receipt rules enable you to specify which actions Amazon SES should take when it receives mail on behalf of one or more email addresses or domains that you own.
Each receipt rule defines a set of email addresses or domains to which it applies. If the email addresses or domains match at least one recipient address of the message, Amazon SES executes all of the receipt rule's actions on the message.
For information about setting up receipt rules, see the Amazon SES Developer Guide .
Constructor and Description |
---|
ReceiptRule() |
Modifier and Type | Method and Description |
---|---|
ReceiptRule |
clone() |
boolean |
equals(Object obj) |
List<ReceiptAction> |
getActions()
An ordered list of actions to perform on messages that match at least
one of the recipient email addresses or domains specified in the
receipt rule.
|
Boolean |
getEnabled()
If
true , the receipt rule is active. |
String |
getName()
The name of the receipt rule.
|
List<String> |
getRecipients()
The recipient domains and email addresses to which the receipt rule
applies.
|
Boolean |
getScanEnabled()
If
true , then messages to which this receipt rule applies
are scanned for spam and viruses. |
String |
getTlsPolicy()
Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS).
|
int |
hashCode() |
Boolean |
isEnabled()
If
true , the receipt rule is active. |
Boolean |
isScanEnabled()
If
true , then messages to which this receipt rule applies
are scanned for spam and viruses. |
void |
setActions(Collection<ReceiptAction> actions)
An ordered list of actions to perform on messages that match at least
one of the recipient email addresses or domains specified in the
receipt rule.
|
void |
setEnabled(Boolean enabled)
If
true , the receipt rule is active. |
void |
setName(String name)
The name of the receipt rule.
|
void |
setRecipients(Collection<String> recipients)
The recipient domains and email addresses to which the receipt rule
applies.
|
void |
setScanEnabled(Boolean scanEnabled)
If
true , then messages to which this receipt rule applies
are scanned for spam and viruses. |
void |
setTlsPolicy(String tlsPolicy)
Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS).
|
void |
setTlsPolicy(TlsPolicy tlsPolicy)
Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS).
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
ReceiptRule |
withActions(Collection<ReceiptAction> actions)
An ordered list of actions to perform on messages that match at least
one of the recipient email addresses or domains specified in the
receipt rule.
|
ReceiptRule |
withActions(ReceiptAction... actions)
An ordered list of actions to perform on messages that match at least
one of the recipient email addresses or domains specified in the
receipt rule.
|
ReceiptRule |
withEnabled(Boolean enabled)
If
true , the receipt rule is active. |
ReceiptRule |
withName(String name)
The name of the receipt rule.
|
ReceiptRule |
withRecipients(Collection<String> recipients)
The recipient domains and email addresses to which the receipt rule
applies.
|
ReceiptRule |
withRecipients(String... recipients)
The recipient domains and email addresses to which the receipt rule
applies.
|
ReceiptRule |
withScanEnabled(Boolean scanEnabled)
If
true , then messages to which this receipt rule applies
are scanned for spam and viruses. |
ReceiptRule |
withTlsPolicy(String tlsPolicy)
Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS).
|
ReceiptRule |
withTlsPolicy(TlsPolicy tlsPolicy)
Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS).
|
public String getName()
public void setName(String name)
name
- The name of the receipt rule. The name must: public ReceiptRule withName(String name)
Returns a reference to this object so that method calls can be chained together.
name
- The name of the receipt rule. The name must: public Boolean isEnabled()
true
, the receipt rule is active. The default value is
true.true
, the receipt rule is active. The default value is
true.public void setEnabled(Boolean enabled)
true
, the receipt rule is active. The default value is
true.enabled
- If true
, the receipt rule is active. The default value is
true.public ReceiptRule withEnabled(Boolean enabled)
true
, the receipt rule is active. The default value is
true.
Returns a reference to this object so that method calls can be chained together.
enabled
- If true
, the receipt rule is active. The default value is
true.public Boolean getEnabled()
true
, the receipt rule is active. The default value is
true.true
, the receipt rule is active. The default value is
true.public String getTlsPolicy()
Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.
Constraints:
Allowed Values: Require, Optional
Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.TlsPolicy
public void setTlsPolicy(String tlsPolicy)
Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.
Constraints:
Allowed Values: Require, Optional
tlsPolicy
- Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS). If this parameter is set to Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.TlsPolicy
public ReceiptRule withTlsPolicy(String tlsPolicy)
Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: Require, Optional
tlsPolicy
- Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS). If this parameter is set to Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.TlsPolicy
public void setTlsPolicy(TlsPolicy tlsPolicy)
Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.
Constraints:
Allowed Values: Require, Optional
tlsPolicy
- Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS). If this parameter is set to Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.TlsPolicy
public ReceiptRule withTlsPolicy(TlsPolicy tlsPolicy)
Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: Require, Optional
tlsPolicy
- Specifies whether Amazon SES should require that incoming email is
delivered over a connection encrypted with Transport Layer Security
(TLS). If this parameter is set to Require
, Amazon SES
will bounce emails that are not received over TLS. The default is
Optional
.TlsPolicy
public List<String> getRecipients()
public void setRecipients(Collection<String> recipients)
recipients
- The recipient domains and email addresses to which the receipt rule
applies. If this field is not specified, this rule will match all
recipients under all verified domains.public ReceiptRule withRecipients(String... recipients)
NOTE: This method appends the values to the existing list (if
any). Use setRecipients(java.util.Collection)
or withRecipients(java.util.Collection)
if you want to override the
existing values.
Returns a reference to this object so that method calls can be chained together.
recipients
- The recipient domains and email addresses to which the receipt rule
applies. If this field is not specified, this rule will match all
recipients under all verified domains.public ReceiptRule withRecipients(Collection<String> recipients)
Returns a reference to this object so that method calls can be chained together.
recipients
- The recipient domains and email addresses to which the receipt rule
applies. If this field is not specified, this rule will match all
recipients under all verified domains.public List<ReceiptAction> getActions()
public void setActions(Collection<ReceiptAction> actions)
actions
- An ordered list of actions to perform on messages that match at least
one of the recipient email addresses or domains specified in the
receipt rule.public ReceiptRule withActions(ReceiptAction... actions)
NOTE: This method appends the values to the existing list (if
any). Use setActions(java.util.Collection)
or withActions(java.util.Collection)
if you want to override the
existing values.
Returns a reference to this object so that method calls can be chained together.
actions
- An ordered list of actions to perform on messages that match at least
one of the recipient email addresses or domains specified in the
receipt rule.public ReceiptRule withActions(Collection<ReceiptAction> actions)
Returns a reference to this object so that method calls can be chained together.
actions
- An ordered list of actions to perform on messages that match at least
one of the recipient email addresses or domains specified in the
receipt rule.public Boolean isScanEnabled()
true
, then messages to which this receipt rule applies
are scanned for spam and viruses. The default value is
true
.true
, then messages to which this receipt rule applies
are scanned for spam and viruses. The default value is
true
.public void setScanEnabled(Boolean scanEnabled)
true
, then messages to which this receipt rule applies
are scanned for spam and viruses. The default value is
true
.scanEnabled
- If true
, then messages to which this receipt rule applies
are scanned for spam and viruses. The default value is
true
.public ReceiptRule withScanEnabled(Boolean scanEnabled)
true
, then messages to which this receipt rule applies
are scanned for spam and viruses. The default value is
true
.
Returns a reference to this object so that method calls can be chained together.
scanEnabled
- If true
, then messages to which this receipt rule applies
are scanned for spam and viruses. The default value is
true
.public Boolean getScanEnabled()
true
, then messages to which this receipt rule applies
are scanned for spam and viruses. The default value is
true
.true
, then messages to which this receipt rule applies
are scanned for spam and viruses. The default value is
true
.public String toString()
toString
in class Object
Object.toString()
public ReceiptRule clone()
Copyright © 2015. All rights reserved.