org.cruxframework.crux.core.client.errors
Class ErrorHandlerImpl

java.lang.Object
  extended by org.cruxframework.crux.core.client.errors.ErrorHandlerImpl
All Implemented Interfaces:
ErrorHandler, ValidationErrorHandler

public class ErrorHandlerImpl
extends Object
implements ErrorHandler, ValidationErrorHandler

Author:
Thiago da Rosa de Bustamante

Constructor Summary
ErrorHandlerImpl()
           
 
Method Summary
 void handleError(String errorMessage)
          Handle an error on application
 void handleError(String errorMessage, Throwable t)
          Handle an error on application
 void handleError(Throwable t)
          Handle an error on application
 void handleError(Throwable t, boolean uncaught)
          Handle an error on application
 void handleValidationError(String errorMessage)
          Handle a validation error
 com.google.gwt.user.client.ui.Widget handleValidationError(com.google.gwt.user.client.ui.Widget widget, String errorMessage)
          Handle a validation error inside a widget
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ErrorHandlerImpl

public ErrorHandlerImpl()
Method Detail

handleError

public void handleError(String errorMessage)
Description copied from interface: ErrorHandler
Handle an error on application

Specified by:
handleError in interface ErrorHandler
Parameters:
errorMessage - The error message

handleError

public void handleError(Throwable t)
Description copied from interface: ErrorHandler
Handle an error on application

Specified by:
handleError in interface ErrorHandler
Parameters:
t - The exception

handleError

public void handleError(String errorMessage,
                        Throwable t)
Description copied from interface: ErrorHandler
Handle an error on application

Specified by:
handleError in interface ErrorHandler
Parameters:
errorMessage - The error message
t - The exception

handleValidationError

public void handleValidationError(String errorMessage)
Description copied from interface: ValidationErrorHandler
Handle a validation error

Specified by:
handleValidationError in interface ValidationErrorHandler
Parameters:
errorMessage - The error message.

handleError

public void handleError(Throwable t,
                        boolean uncaught)
Description copied from interface: ErrorHandler
Handle an error on application

Specified by:
handleError in interface ErrorHandler
Parameters:
t - The exception
uncaught - True if it is an uncaught exception

handleValidationError

public com.google.gwt.user.client.ui.Widget handleValidationError(com.google.gwt.user.client.ui.Widget widget,
                                                                  String errorMessage)
Description copied from interface: ValidationErrorHandler
Handle a validation error inside a widget

Specified by:
handleValidationError in interface ValidationErrorHandler
Parameters:
widget - the corresponding widget to be marked as invalid
errorMessage - The error message.
Returns:
the widget appended to the errorElement


Copyright © 2014. All rights reserved.