Package mireka.transmission
Class Mail
- Object
-
- mireka.transmission.Mail
-
public class Mail extends ObjectAn SMTP mail object, which contains both an envelope and content.- See Also:
- RFC 5321 Simple Mail Transfer Protocol
-
-
Field Summary
Fields Modifier and Type Field Description java.util.DatearrivalDateIf the message was generated locally then this time should be the date of creation.intdeliveryAttemptsCount of failed attempts until now.ReversePathfromMailDatamailDataintpostponesCount of postponings of delivery attempts since the last actually performed attempt.java.net.InetAddressreceivedFromMtaAddressnull if the mail was generated locallyStringreceivedFromMtaNameHELO or EHLO name, null if not receivedjava.util.List<Recipient>recipientsjava.util.DatescheduleDateThe desired date of sending this mail.
-
Constructor Summary
Constructors Constructor Description Mail()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Mailcopy()Creates an essentially deep copy of this instance.StringtoString()Returns a short descriptive information about the mail, useful for logging.
-
-
-
Field Detail
-
from
@Nonnull public ReversePath from
-
recipients
@Nonnull public java.util.List<Recipient> recipients
-
mailData
public MailData mailData
-
arrivalDate
@Nonnull public java.util.Date arrivalDate
If the message was generated locally then this time should be the date of creation.
-
receivedFromMtaName
@Nullable public String receivedFromMtaName
HELO or EHLO name, null if not received
-
receivedFromMtaAddress
@Nullable public java.net.InetAddress receivedFromMtaAddress
null if the mail was generated locally
-
scheduleDate
public java.util.Date scheduleDate
The desired date of sending this mail. Null means immediately.
-
deliveryAttempts
public int deliveryAttempts
Count of failed attempts until now.
-
postpones
public int postpones
Count of postponings of delivery attempts since the last actually performed attempt. Postponing a delivery means that no remote SMTP hosts were connected, so a postponed delivery attempt must not be considered as a retry.
-
-
Method Detail
-
copy
public Mail copy()
Creates an essentially deep copy of this instance. The samemailDataobject is used, otherwise every other field is a deep copy.- Returns:
- A deep copy of this mail, except the
mailDataobject, which is used in both the new and in this object.
-
toString
public String toString()
Returns a short descriptive information about the mail, useful for logging.- Overrides:
toStringin classObject
-
-