org.springframework.richclient.exceptionhandling.delegation
Class AbstractExceptionHandlerDelegate
java.lang.Object
org.springframework.richclient.exceptionhandling.delegation.AbstractExceptionHandlerDelegate
- All Implemented Interfaces:
- Thread.UncaughtExceptionHandler, ExceptionHandlerDelegate
- Direct Known Subclasses:
- ChainInspectingExceptionHandlerDelegate, SimpleExceptionHandlerDelegate
public abstract class AbstractExceptionHandlerDelegate
- extends Object
- implements ExceptionHandlerDelegate
Superclass for delegate implementations
- Since:
- 0.3.0
- Author:
- Geoffrey De Smet
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
exceptionHandler
protected Thread.UncaughtExceptionHandler exceptionHandler
exceptionPurger
protected ExceptionPurger exceptionPurger
purgeOnAppropriateCheck
protected boolean purgeOnAppropriateCheck
purgeOnHandling
protected boolean purgeOnHandling
AbstractExceptionHandlerDelegate
public AbstractExceptionHandlerDelegate()
AbstractExceptionHandlerDelegate
public AbstractExceptionHandlerDelegate(Thread.UncaughtExceptionHandler exceptionHandler)
setExceptionHandler
public void setExceptionHandler(Thread.UncaughtExceptionHandler exceptionHandler)
setExceptionPurger
public void setExceptionPurger(ExceptionPurger exceptionPurger)
- If set the throwable will first be purged before doing the approriate check or handling it.
- Parameters:
exceptionPurger
-
setPurgeOnAppropriateCheck
public void setPurgeOnAppropriateCheck(boolean purgeOnAppropriateCheck)
setPurgeOnHandling
public void setPurgeOnHandling(boolean purgeOnHandling)
hasAppropriateHandler
public final boolean hasAppropriateHandler(Throwable throwable)
- Checks if the delegate wants to handle the throwable.
- Specified by:
hasAppropriateHandler
in interface ExceptionHandlerDelegate
- Parameters:
throwable
- the thrown exception or error.
- Returns:
- true if this exception handler wants to handle the throwable.
hasAppropriateHandlerPurged
public abstract boolean hasAppropriateHandlerPurged(Throwable throwable)
uncaughtException
public final void uncaughtException(Thread thread,
Throwable throwable)
-
- Specified by:
uncaughtException
in interface Thread.UncaughtExceptionHandler
uncaughtExceptionPurged
public void uncaughtExceptionPurged(Thread thread,
Throwable throwable)
Copyright © 2004-2008 The Spring Framework. All Rights Reserved.