java.io.Serializable
public class TransportEvent extends MailEvent
Transport
,
TransportListener
,
Serialized FormModifier and Type | Field | Description |
---|---|---|
protected Address[] |
invalid |
The invalid addresses.
|
static int |
MESSAGE_DELIVERED |
Message has been successfully delivered to all recipients by the
transport firing this event.
|
static int |
MESSAGE_NOT_DELIVERED |
Message was not sent for some reason.
|
static int |
MESSAGE_PARTIALLY_DELIVERED |
Message was successfully sent to some recipients but not to all.
|
protected Message |
msg |
The Message to which this event applies.
|
protected int |
type |
The event type.
|
protected Address[] |
validSent |
The valid address to which the message was sent.
|
protected Address[] |
validUnsent |
The valid address to which the message was not sent.
|
Constructor | Description |
---|---|
TransportEvent(Transport transport,
int type,
Address[] validSent,
Address[] validUnsent,
Address[] invalid,
Message msg) |
Constructor.
|
Modifier and Type | Method | Description |
---|---|---|
void |
dispatch(java.lang.Object listener) |
Invokes the appropriate TransportListener method.
|
Address[] |
getInvalidAddresses() |
Return the addresses to which this message could not be sent.
|
Message |
getMessage() |
Get the Message object associated with this Transport Event.
|
int |
getType() |
Return the type of this event.
|
Address[] |
getValidSentAddresses() |
Return the addresses to which this message was sent succesfully.
|
Address[] |
getValidUnsentAddresses() |
Return the addresses that are valid but to which this message
was not sent.
|
public static final int MESSAGE_DELIVERED
public static final int MESSAGE_NOT_DELIVERED
public static final int MESSAGE_PARTIALLY_DELIVERED
protected int type
protected transient Address[] validSent
protected transient Address[] validUnsent
protected transient Address[] invalid
protected transient Message msg
public TransportEvent(Transport transport, int type, Address[] validSent, Address[] validUnsent, Address[] invalid, Message msg)
transport
- The Transport objecttype
- the event type (MESSAGE_DELIVERED, etc.)validSent
- the valid addresses to which the message was sentvalidUnsent
- the valid addresses to which the message was
not sentinvalid
- the invalid addressesmsg
- the message being sentpublic int getType()
public Address[] getValidSentAddresses()
public Address[] getValidUnsentAddresses()
public Address[] getInvalidAddresses()
public Message getMessage()
Copyright © 2018 Oracle. All rights reserved.