java.lang.Object
java.lang.Throwable
java.lang.Exception
jakarta.mail.MessagingException
org.eclipse.angus.mail.util.MailConnectException
- All Implemented Interfaces:
Serializable
A MessagingException that indicates a socket connection attempt failed.
Unlike java.net.ConnectException, it includes details of what we
were trying to connect to. The underlying exception is available
as the "cause" of this exception.
- Since:
- JavaMail 1.5.0
- See Also:
-
Constructor Summary
ConstructorDescriptionMailConnectException
(org.eclipse.angus.mail.util.SocketConnectException cex) Constructs a MailConnectException. -
Method Summary
Methods inherited from class jakarta.mail.MessagingException
getCause, getNextException, setNextException, toString
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
Constructor Details
-
MailConnectException
public MailConnectException(org.eclipse.angus.mail.util.SocketConnectException cex) Constructs a MailConnectException.- Parameters:
cex
- the SocketConnectException with the details
-
-
Method Details
-
getHost
The host we were trying to connect to.- Returns:
- the host
-
getPort
public int getPort()The port we were trying to connect to.- Returns:
- the port
-
getConnectionTimeout
public int getConnectionTimeout()The timeout used for the connection attempt.- Returns:
- the connection timeout
-