public class ExceptionHandlerImpl
extends javax.faces.context.ExceptionHandler
The default implementation of ExceptionHandler
for JSF 2.0.
As an implementation note, if changes going forward are required here,
review the ExceptionHandler
implementation within
javax.faces.webapp.PreJsf2ExceptionHandlerFactory
. The code
is, in most cases, quite similar.
Modifier and Type | Field and Description |
---|---|
private boolean |
errorPagePresent |
private javax.faces.event.ExceptionQueuedEvent |
handled |
private java.util.LinkedList<javax.faces.event.ExceptionQueuedEvent> |
handledExceptions |
static java.util.logging.Level |
INCIDENT_ERROR |
private static java.lang.String |
LOG_AFTER_KEY |
private static java.lang.String |
LOG_BEFORE_KEY |
private static java.lang.String |
LOG_KEY |
private static java.util.logging.Logger |
LOGGER |
private java.util.LinkedList<javax.faces.event.ExceptionQueuedEvent> |
unhandledExceptions |
Constructor and Description |
---|
ExceptionHandlerImpl() |
ExceptionHandlerImpl(boolean errorPagePresent) |
Modifier and Type | Method and Description |
---|---|
javax.faces.event.ExceptionQueuedEvent |
getHandledExceptionQueuedEvent() |
java.lang.Iterable<javax.faces.event.ExceptionQueuedEvent> |
getHandledExceptionQueuedEvents() |
private java.lang.String |
getLoggingKey(boolean beforePhase,
boolean afterPhase) |
java.lang.Throwable |
getRootCause(java.lang.Throwable t) |
java.lang.Iterable<javax.faces.event.ExceptionQueuedEvent> |
getUnhandledExceptionQueuedEvents() |
void |
handle() |
boolean |
isListenerForSource(java.lang.Object source) |
private boolean |
isRethrown(java.lang.Throwable t) |
private void |
log(javax.faces.event.ExceptionQueuedEventContext exceptionContext) |
void |
processEvent(javax.faces.event.SystemEvent event) |
private boolean |
shouldUnwrap(java.lang.Class<? extends java.lang.Throwable> c) |
private void |
throwIt(javax.faces.context.FacesContext ctx,
javax.faces.FacesException fe) |
private static final java.util.logging.Logger LOGGER
private static final java.lang.String LOG_BEFORE_KEY
private static final java.lang.String LOG_AFTER_KEY
private static final java.lang.String LOG_KEY
public static final java.util.logging.Level INCIDENT_ERROR
private java.util.LinkedList<javax.faces.event.ExceptionQueuedEvent> unhandledExceptions
private java.util.LinkedList<javax.faces.event.ExceptionQueuedEvent> handledExceptions
private javax.faces.event.ExceptionQueuedEvent handled
private boolean errorPagePresent
public ExceptionHandlerImpl()
public ExceptionHandlerImpl(boolean errorPagePresent)
public javax.faces.event.ExceptionQueuedEvent getHandledExceptionQueuedEvent()
getHandledExceptionQueuedEvent
in class javax.faces.context.ExceptionHandler
public void handle() throws javax.faces.FacesException
handle
in class javax.faces.context.ExceptionHandler
javax.faces.FacesException
ExceptionHandler.handle()
public boolean isListenerForSource(java.lang.Object source)
isListenerForSource
in interface javax.faces.event.SystemEventListener
isListenerForSource
in class javax.faces.context.ExceptionHandler
ExceptionHandler.isListenerForSource(Object)
public void processEvent(javax.faces.event.SystemEvent event) throws javax.faces.event.AbortProcessingException
processEvent
in interface javax.faces.event.SystemEventListener
processEvent
in class javax.faces.context.ExceptionHandler
javax.faces.event.AbortProcessingException
ExceptionHandler.processEvent(javax.faces.event.SystemEvent)
public java.lang.Throwable getRootCause(java.lang.Throwable t)
getRootCause
in class javax.faces.context.ExceptionHandler
ExceptionHandler.getRootCause(Throwable)
public java.lang.Iterable<javax.faces.event.ExceptionQueuedEvent> getUnhandledExceptionQueuedEvents()
getUnhandledExceptionQueuedEvents
in class javax.faces.context.ExceptionHandler
ExceptionHandler.getUnhandledExceptionQueuedEvents()
public java.lang.Iterable<javax.faces.event.ExceptionQueuedEvent> getHandledExceptionQueuedEvents()
getHandledExceptionQueuedEvents
in class javax.faces.context.ExceptionHandler
ExceptionHandler.getHandledExceptionQueuedEvents()
private void throwIt(javax.faces.context.FacesContext ctx, javax.faces.FacesException fe)
private boolean shouldUnwrap(java.lang.Class<? extends java.lang.Throwable> c)
c
- Throwable
implementation classtrue
if c
is FacesException.class or
ELException.classprivate boolean isRethrown(java.lang.Throwable t)
private void log(javax.faces.event.ExceptionQueuedEventContext exceptionContext)
private java.lang.String getLoggingKey(boolean beforePhase, boolean afterPhase)
Copyright © 2002-2013 Oracle America, Inc. All Rights Reserved.