Class ExceptionErrorPage
- java.lang.Object
-
- org.apache.wicket.Component
-
- org.apache.wicket.MarkupContainer
-
- org.apache.wicket.Page
-
- org.apache.wicket.markup.html.WebPage
-
- org.apache.wicket.markup.html.pages.AbstractErrorPage
-
- org.apache.wicket.markup.html.pages.ExceptionErrorPage
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Iterable<Component>,IEventSink,IEventSource,IFeedbackContributor,IConverterLocator,IMetadataContext<java.io.Serializable,Component>,IQueueRegion,IHeaderContributor,IManageablePage,IRequestableComponent,IRequestablePage,org.apache.wicket.util.IHierarchical<Component>,org.apache.wicket.util.io.IClusterable
public class ExceptionErrorPage extends AbstractErrorPage
Shows a runtime exception on a nice HTML page.- Author:
- Jonathan Locke
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.apache.wicket.Component
ENABLE, FLAG_INITIALIZED, FLAG_RESERVED1, FLAG_RESERVED2, FLAG_RESERVED3, FLAG_RESERVED4, FLAG_RESERVED5, FLAG_RESERVED8, PARENT_PATH, PATH_SEPARATOR, RENDER, RFLAG_CONTAINER_DEQUEING
-
-
Constructor Summary
Constructors Constructor Description ExceptionErrorPage(java.lang.Throwable throwable, Page page)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetErrorMessage(java.lang.Throwable throwable)Converts a Throwable to a string.java.lang.StringgetStackTrace(java.lang.Throwable throwable)Converts a Throwable to a string.java.lang.ThrowablegetThrowable()Get access to the exceptionprotected voidsetHeaders(org.apache.wicket.request.http.WebResponse response)Subclasses can override this to set there headers when the Page is being served.-
Methods inherited from class org.apache.wicket.markup.html.pages.AbstractErrorPage
isErrorPage, isVersioned
-
Methods inherited from class org.apache.wicket.markup.html.WebPage
configureResponse, dirty, getMarkupType, homePageLink, onAfterRender, onRender, renderXmlDecl, reportMissingHead
-
Methods inherited from class org.apache.wicket.Page
componentChanged, componentRendered, detachModels, dirty, getAutoIndex, getId, getPageClass, getPageId, getPageParameters, getPageReference, getRenderCount, getSizeInBytes, getStatelessHint, hierarchyAsString, internalOnModelChanged, isBookmarkable, isPageStateless, onBeforeRender, onConfigure, onDetach, onInitialize, renderPage, setFreezePageId, setNumericId, setStatelessHint, setWasCreatedBookmarkable, toString, wasCreatedBookmarkable, wasRendered
-
Methods inherited from class org.apache.wicket.MarkupContainer
add, addDequeuedComponent, addOrReplace, autoAdd, canDequeueTag, contains, dequeue, dequeue, dequeuePreamble, findChildComponent, findComponentToDequeue, get, getAssociatedMarkup, getAssociatedMarkupStream, getMarkup, getRegionMarkup, internalAdd, internalInitialize, iterator, iterator, newDequeueContext, onComponentTagBody, queue, remove, remove, removeAll, renderAll, renderAssociatedMarkup, renderNext, replace, setDefaultModel, size, stream, streamChildren, toString, visitChildren, visitChildren
-
Methods inherited from class org.apache.wicket.Component
add, addStateChange, beforeRender, canCallListener, canCallListenerAfterExpiry, checkComponentTag, checkComponentTagAttribute, checkHierarchyChange, clearOriginalDestination, configure, continueToOriginalDestination, createConverter, debug, detach, detachModel, determineVisibility, error, exceptionMessage, fatal, findMarkupStream, findPage, findParent, findParentWithAssociatedMarkup, getAjaxRegionMarkupId, getApplication, getBehaviorById, getBehaviorId, getBehaviors, getBehaviors, getClassRelativePath, getConverter, getDefaultModel, getDefaultModelObject, getDefaultModelObjectAsString, getDefaultModelObjectAsString, getEscapeModelStrings, getFeedbackMessages, getFlag, getInnermostModel, getInnermostModel, getLocale, getLocalizer, getMarkup, getMarkupAttributes, getMarkupId, getMarkupId, getMarkupIdFromMarkup, getMarkupIdImpl, getMarkupSourcingStrategy, getMetaData, getModelComparator, getOutputMarkupId, getOutputMarkupPlaceholderTag, getPage, getPageRelativePath, getParent, getPath, getRenderBodyOnly, getRequest, getRequestCycle, getRequestFlag, getResponse, getSession, getString, getString, getString, getStyle, getVariation, hasBeenRendered, hasErrorMessage, hasFeedbackMessage, info, initModel, internalRenderComponent, internalRenderHead, isActionAuthorized, isAuto, isBehaviorAccepted, isEnableAllowed, isEnabled, isEnabledInHierarchy, isIgnoreAttributeModifier, isInitialized, isRenderAllowed, isRendering, isStateless, isVisibilityAllowed, isVisible, isVisibleInHierarchy, markRendering, modelChanged, modelChanging, newMarkupSourcingStrategy, onComponentTag, onEvent, onModelChanged, onModelChanging, onReAdd, onRemove, redirectToInterceptPage, remove, remove, render, renderComponentTag, rendered, renderHead, renderPart, renderPlaceholderTag, replaceComponentTagBody, replaceWith, sameInnermostModel, sameInnermostModel, send, setAuto, setDefaultModelObject, setEnabled, setEscapeModelStrings, setFlag, setIgnoreAttributeModifier, setMarkup, setMarkupId, setMarkupIdImpl, setMetaData, setOutputMarkupId, setOutputMarkupPlaceholderTag, setParent, setRenderBodyOnly, setResponsePage, setResponsePage, setResponsePage, setVersioned, setVisibilityAllowed, setVisible, success, urlFor, urlFor, urlFor, urlForListener, urlForListener, visitParents, visitParents, warn, wrap
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.apache.wicket.page.IManageablePage
detach
-
Methods inherited from interface org.apache.wicket.IQueueRegion
dequeue, getRegionMarkup, newDequeueContext
-
Methods inherited from interface org.apache.wicket.request.component.IRequestableComponent
canCallListenerAfterExpiry, detach, get, getBehaviorById, getBehaviorId, getPage, getPageRelativePath
-
-
-
-
Constructor Detail
-
ExceptionErrorPage
public ExceptionErrorPage(java.lang.Throwable throwable, Page page)Constructor.- Parameters:
throwable- The exception to showpage- The page being rendered when the exception was thrown
-
-
Method Detail
-
getErrorMessage
public java.lang.String getErrorMessage(java.lang.Throwable throwable)
Converts a Throwable to a string.- Parameters:
throwable- The throwable- Returns:
- The string
-
getStackTrace
public java.lang.String getStackTrace(java.lang.Throwable throwable)
Converts a Throwable to a string.- Parameters:
throwable- The throwable- Returns:
- The string
-
setHeaders
protected void setHeaders(org.apache.wicket.request.http.WebResponse response)
Description copied from class:WebPageSubclasses can override this to set there headers when the Page is being served. By default these headers are set:response.setHeader("Date", "[now]"); response.setHeader("Expires", "[0]"); response.setHeader("Pragma", "no-cache"); response.setHeader("Cache-Control", "no-cache");So if a Page wants to control this or doesn't want to set this info it should override this method and don't call super.- Overrides:
setHeadersin classWebPage- Parameters:
response- The WebResponse where set(Date)Header can be called on.
-
getThrowable
public java.lang.Throwable getThrowable()
Get access to the exception- Returns:
- The exception
-
-