public class DefaultErrorHandler extends Object implements ErrorHandler
ErrorHandler implementation.
If there is a MaterialHelpBlock that is a child then error messages
will be displayed in the MaterialHelpBlock.
Example:
<m:MaterialRow>
<m:TextBox m:id="username" ui:field="username" />
<m:MaterialHelpBlock iconType="EXCLAMATION" />
</m:MaterialRow>
| Constructor and Description |
|---|
DefaultErrorHandler(com.google.gwt.user.client.ui.Widget widget)
Default error handler.
|
| Modifier and Type | Method and Description |
|---|---|
void |
cleanup()
Clean up the handler if necessary.
|
void |
clearErrors()
Clear any errors.
|
protected MaterialHelpBlock |
findHelpBlock(com.google.gwt.user.client.ui.Widget widget)
Find the sibling
MaterialHelpBlock. |
void |
init()
Initialize the instance.
|
void |
showErrors(List<com.google.gwt.editor.client.EditorError> errors)
Show the errors on the input screen.
|
public DefaultErrorHandler(com.google.gwt.user.client.ui.Widget widget)
widget - the parent of this error handler.public void cleanup()
ErrorHandlercleanup in interface ErrorHandlerpublic void clearErrors()
ErrorHandlerclearErrors in interface ErrorHandlerprotected MaterialHelpBlock findHelpBlock(com.google.gwt.user.client.ui.Widget widget)
MaterialHelpBlock.widget - the Widget to search.MaterialHelpBlock of null if not found.public void init()
public void showErrors(List<com.google.gwt.editor.client.EditorError> errors)
ErrorHandlershowErrors in interface ErrorHandlererrors - the errors to display.Copyright © 2018. All rights reserved.