|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.jaxfront.core.type.ErrorController
public class ErrorController
The TypeController controls any value changes in the underlying JAXFront DOM. If a value changed the TypeController checks all relevant rules defined in the XUI document. He keeps track of all occured validation errors. In case of a validation error, a ValidationChangeEvent gets fired.
| Constructor Summary | |
|---|---|
ErrorController(TypeController controller)
|
|
| Method Summary | |
|---|---|
void |
addError(Error error)
Adds a validationError |
void |
addError(Error error,
boolean shouldFireEvent)
Adds a validationError |
void |
addValidationChangeListener(ValidationChangeListener newListener)
Adds a validationChangeListener. |
void |
fireUnhandledValidationExceptions()
|
java.util.Collection |
getAllErrors()
|
java.util.Collection |
getAllErrors(java.util.Comparator comparator)
|
java.util.Collection |
getAllErrors(java.util.Hashtable errorMap,
int errorType)
|
java.util.Collection |
getAllErrors(int errorType)
|
TypeController |
getController()
|
java.util.Hashtable |
getErrors()
Returns all current validationErrors. |
java.util.Vector |
getErrorsForClassification(java.lang.String errorClassification)
Returns all current validationErrors for the given category (e.g. error, info, question, ...). |
java.util.Vector |
getErrorsForType(Type source)
|
java.util.Vector |
getErrorsForType(Type source,
int errorType)
|
java.util.Collection |
getOptimizedErrors()
|
java.util.Collection |
getOptimizedErrors(java.util.Comparator comparator)
|
void |
handleValidationException(Type type,
ValidationException exception)
|
boolean |
hasPageErrors(Type type,
boolean validate)
Returns whether a type's represented tree node parent has errors or not. |
boolean |
hasValidationErrors()
Returns whether any current validationErrors exist or not. |
boolean |
isBlocked()
|
void |
maintainErrors(Type removedType)
Removes validation errors for all errors where the source type is derived from the passing type. |
void |
release()
Releases rules, validationErrors, validationChangeListener and propertyChangeSupport. |
void |
removeAllErrors(boolean fireEvent)
Removes all current validation errors of the given DOM. |
void |
removeConditionalError(Rule rule,
ConditionExpression condition,
Type sourceType)
|
void |
removeError(Error error)
Removes the validationError of the give source type. |
void |
removeError(Error error,
boolean shouldFireEvent)
Removes the validationError of the give source type. |
void |
removeError(Type errorHolder)
Removes the validationError of the give source type. |
void |
removeErrors(java.util.List errors)
|
void |
removeErrors(java.util.List errors,
boolean fireEvent)
|
void |
removeMandatoryAndCardinalityValidationErrors()
Removes all mandatory violation exceptions. |
void |
removeMandatoryAndCardinalityValidationErrors(Type type)
Removes all mandatory violation exceptions for a given type. |
void |
removeUserError(java.lang.Object identifierObject,
Type sourceType)
|
void |
removeValidationChangeListener(ValidationChangeListener newListener)
Removes the given ValidationChangeListener. |
void |
removeValidationError(Type sourceType)
|
void |
setBlocked(boolean blocked)
|
void |
setErrorsDelegate(java.util.Hashtable delegate)
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ErrorController(TypeController controller)
| Method Detail |
|---|
public void addError(Error error)
ex - a validation exception that should be addedsource - the type on which the error occured
public void addError(Error error,
boolean shouldFireEvent)
ex - a validation exception that should be addedshouldFireEvent - indicates if an validationChanged Event should be firedpublic void addValidationChangeListener(ValidationChangeListener newListener)
newListener - a validationChangeListener that should be addedpublic void fireUnhandledValidationExceptions()
public java.util.Collection getAllErrors()
public java.util.Collection getAllErrors(java.util.Comparator comparator)
public java.util.Collection getAllErrors(java.util.Hashtable errorMap,
int errorType)
public java.util.Collection getAllErrors(int errorType)
public TypeController getController()
public java.util.Hashtable getErrors()
public java.util.Vector getErrorsForClassification(java.lang.String errorClassification)
public java.util.Vector getErrorsForType(Type source)
public java.util.Vector getErrorsForType(Type source,
int errorType)
public java.util.Collection getOptimizedErrors()
public java.util.Collection getOptimizedErrors(java.util.Comparator comparator)
public void handleValidationException(Type type,
ValidationException exception)
public boolean hasPageErrors(Type type,
boolean validate)
type - the type of which the represented tree node parent will be checked for errors
public boolean hasValidationErrors()
public boolean isBlocked()
public void maintainErrors(Type removedType)
removedType - type which has been removed from DOMpublic void release()
public void removeAllErrors(boolean fireEvent)
dom - a document for which the validation errors should be removed
public void removeConditionalError(Rule rule,
ConditionExpression condition,
Type sourceType)
public void removeError(Error error)
source - a type that has an error
public void removeError(Error error,
boolean shouldFireEvent)
source - a type that has an errorpublic void removeError(Type errorHolder)
source - a type that has an errorpublic void removeErrors(java.util.List errors)
public void removeErrors(java.util.List errors,
boolean fireEvent)
public void removeMandatoryAndCardinalityValidationErrors()
public void removeMandatoryAndCardinalityValidationErrors(Type type)
public void removeUserError(java.lang.Object identifierObject,
Type sourceType)
public void removeValidationChangeListener(ValidationChangeListener newListener)
listener - a ValidationChangeListener that should be removedpublic void removeValidationError(Type sourceType)
public void setBlocked(boolean blocked)
public void setErrorsDelegate(java.util.Hashtable delegate)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||