javax.mail

Class SendFailedException

public class SendFailedException extends MessagingException

An exception thrown when a message cannot be sent.

It includes those addresses to which the message could not be sent as well as the valid addresses to which the message was sent and valid addresses to which the message was not sent.

Version: 1.3

Author: Chris Burdess

Field Summary
protected Address[]invalid
protected Address[]validSent
protected Address[]validUnsent
Constructor Summary
SendFailedException()
SendFailedException(String message)
SendFailedException(String message, Exception exception)
SendFailedException(String message, Exception exception, Address[] validSent, Address[] validUnsent, Address[] invalid)
Creates a send failed exception with the specified string and addresses.
Method Summary
Address[]getInvalidAddresses()
Returns the addresses to which this message could not be sent.
Address[]getValidSentAddresses()
Returns the addresses to which this message was sent succesfully.
Address[]getValidUnsentAddresses()
Returns the addresses that are valid but to which this message was not sent.

Field Detail

invalid

protected transient Address[] invalid

validSent

protected transient Address[] validSent

validUnsent

protected transient Address[] validUnsent

Constructor Detail

SendFailedException

public SendFailedException()

SendFailedException

public SendFailedException(String message)

SendFailedException

public SendFailedException(String message, Exception exception)

SendFailedException

public SendFailedException(String message, Exception exception, Address[] validSent, Address[] validUnsent, Address[] invalid)
Creates a send failed exception with the specified string and addresses.

Parameters: message the detail message exception the embedded exception validSent valid addresses to which message was sent validUnsent valid addresses to which message was not sent invalid the invalid addresses

Method Detail

getInvalidAddresses

public Address[] getInvalidAddresses()
Returns the addresses to which this message could not be sent.

getValidSentAddresses

public Address[] getValidSentAddresses()
Returns the addresses to which this message was sent succesfully.

getValidUnsentAddresses

public Address[] getValidUnsentAddresses()
Returns the addresses that are valid but to which this message was not sent.
©