textbender.g.lang
Class CatcherL<S>

java.lang.Object
  extended by CatcherL<S>
All Implemented Interfaces:
Catcher<S>

public class CatcherL<S>
extends Object
implements Catcher<S>

A catcher that logs exceptions, but rethrows errors.


Nested Class Summary
 
Nested classes/interfaces inherited from interface Catcher
Catcher.X
 
Constructor Summary
CatcherL()
           
 
Method Summary
 void catchError(S source, Error r)
          Immediately re-throws the error.
 void catchException(S source, Exception x)
          Logs a full stack trace of the exception.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CatcherL

public CatcherL()
Method Detail

catchError

@ThreadSafe
public void catchError(S source,
                                  Error r)
Immediately re-throws the error. Subclasses that override this method would normally also re-throw it (or call super.catchError) taking care not to drop it first.

Specified by:
catchError in interface Catcher<S>
Parameters:
source - logical source of the error

catchException

@ThreadSafe
public void catchException(S source,
                                      Exception x)
Logs a full stack trace of the exception. using the source's associated logger.

Specified by:
catchException in interface Catcher<S>
Parameters:
source - logical source of the exception