public class ValidatorException extends PortletException
ValidatorException
is thrown by the
validate
method of a PreferencesValidator when
the validation of a preference failed.Modifier and Type | Field and Description |
---|---|
private java.util.ArrayList<java.lang.String> |
failedKeyVector |
private static long |
serialVersionUID |
Modifier | Constructor and Description |
---|---|
private |
ValidatorException() |
|
ValidatorException(java.lang.String text,
java.util.Collection<java.lang.String> failedKeys)
Constructs a new validator exception with the given text.
|
|
ValidatorException(java.lang.String text,
java.lang.Throwable cause,
java.util.Collection<java.lang.String> failedKeys)
Constructs a new portlet validator exception.
|
|
ValidatorException(java.lang.Throwable cause,
java.util.Collection<java.lang.String> failedKeys)
Constructs a new portlet validator exception when the portlet needs to throw an
exception.
|
Modifier and Type | Method and Description |
---|---|
java.util.Enumeration<java.lang.String> |
getFailedKeys()
Returns the keys that failed the validation.
|
private transient java.util.ArrayList<java.lang.String> failedKeyVector
private static final long serialVersionUID
private ValidatorException()
public ValidatorException(java.lang.String text, java.util.Collection<java.lang.String> failedKeys)
The collection of failed keys may contain all failed keys, only the
first key that failed validation, or may be null
.
text
- the exception textfailedKeys
- keys that failed the validation; may be null
public ValidatorException(java.lang.String text, java.lang.Throwable cause, java.util.Collection<java.lang.String> failedKeys)
The Collection of failed keys may contain all failed keys, only the
first key that failed validation, or may be null
.
text
- the exception textcause
- the root causefailedKeys
- keys that failed the validation; may be null
public ValidatorException(java.lang.Throwable cause, java.util.Collection<java.lang.String> failedKeys)
The Collection of failed keys may contain all failed keys, only the
first key that failed validation, or may be null
.
cause
- the root causefailedKeys
- keys that failed the validation; may be null
public java.util.Enumeration<java.lang.String> getFailedKeys()
The Enumeration of failed keys may contain all failed keys, only the
first key that failed validation, or an empty
Enumeration
if no failed keys are available.
Enumeration
if no failed keys are available.