public class InvalidEmailException
extends java.lang.Exception
| Modifier and Type | Field and Description |
|---|---|
static int |
DENIED_DOMAIN_ERROR
Indicates email address contains a denied domain as defined in EmailInspector instance.
|
static int |
INVALID_DOMAIN_ERROR
Indicates email address contains an invalid domain name.
|
static int |
INVALID_MX_ERROR
Indicates error locating SMTP server for email address.
|
static int |
INVALID_SYNTAX_ERROR
Indicates syntax error in email address.
|
static int |
INVALID_USER_ERROR
Indicates invalid user portion of email address.
|
static int |
IO_ERROR
Indicates I/O error communicating with DNS Nameserver or SMTP server.
|
| Constructor and Description |
|---|
InvalidEmailException(java.lang.String email,
int errorCode)
Exception thrown to handle an invalid email.
|
InvalidEmailException(java.lang.String message,
java.lang.String email)
Creates exception with specified message string.
|
InvalidEmailException(java.lang.String message,
java.lang.String email,
java.lang.Throwable cause)
Creates exception with specified message String, email and base exception.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getEmail()
Gets the EmailAddress associated with this exception.
|
int |
getErrorCode()
Gets error code associated with error.
|
java.lang.String |
getMessage()
Gets error message for this exception.
|
public static final int IO_ERROR
public static final int INVALID_SYNTAX_ERROR
public static final int DENIED_DOMAIN_ERROR
public static final int INVALID_DOMAIN_ERROR
public static final int INVALID_MX_ERROR
public static final int INVALID_USER_ERROR
public InvalidEmailException(java.lang.String message,
java.lang.String email)
message - the error messageemail - the email addresspublic InvalidEmailException(java.lang.String message,
java.lang.String email,
java.lang.Throwable cause)
message - the error messageemail - the email addresscause - the exception which generated this exceptionpublic InvalidEmailException(java.lang.String email,
int errorCode)
email - the emailerrorCode - the type of error encounteredpublic java.lang.String getEmail()
public int getErrorCode()
IO_ERROR,
INVALID_SYNTAX_ERROR,
INVALID_DOMAIN_ERROR,
DENIED_DOMAIN_ERROR,
INVALID_MX_ERROR,
INVALID_USER_ERRORpublic java.lang.String getMessage()
getMessage in class java.lang.ThrowableCopyright © JSCAPE LLC. 1999-2021. All Rights Reserved