Class UIDebug
- java.lang.Object
-
- jakarta.faces.component.UIComponent
-
- jakarta.faces.component.UIComponentBase
-
- com.sun.faces.facelets.tag.ui.UIDebug
-
- All Implemented Interfaces:
PartialStateHolder
,StateHolder
,TransientStateHolder
,ComponentSystemEventListener
,FacesListener
,SystemEventListenerHolder
,EventListener
public final class UIDebug extends UIComponentBase
- Author:
- Jacob Hookom
-
-
Field Summary
Fields Modifier and Type Field Description static String
COMPONENT_FAMILY
static String
COMPONENT_TYPE
static String
DEFAULT_HOTKEY
-
Fields inherited from class jakarta.faces.component.UIComponent
ATTRS_WITH_DECLARED_DEFAULT_VALUES, BEANINFO_KEY, bindings, COMPOSITE_COMPONENT_TYPE_KEY, COMPOSITE_FACET_NAME, FACETS_KEY, VIEW_LOCATION_KEY
-
-
Constructor Summary
Constructors Constructor Description UIDebug()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static boolean
debugRequest(FacesContext faces)
void
encodeBegin(FacesContext facesContext)
If ourrendered
property istrue
, render the beginning of the current state of thisUIComponent
to the response contained in the specifiedFacesContext
.List
getChildren()
String
getFamily()
Return the identifier of the component family to which this component belongs.String
getHotkey()
void
setHotkey(String hotkey)
-
Methods inherited from class jakarta.faces.component.UIComponentBase
addClientBehavior, addFacesListener, broadcast, clearInitialState, decode, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getClientBehaviors, getClientId, getDefaultEventName, getEventNames, getFacesContext, getFacesListeners, getFacet, getFacetCount, getFacets, getFacetsAndChildren, getId, getListenersForEventClass, getParent, getPassThroughAttributes, getRenderer, getRendererType, getRendersChildren, invokeOnComponent, isRendered, isTransient, markInitialState, processDecodes, processRestoreState, processSaveState, processUpdates, processValidators, queueEvent, removeFacesListener, restoreAttachedState, restoreState, saveAttachedState, saveState, setId, setParent, setRendered, setRendererType, setTransient, subscribeToEvent, unsubscribeFromEvent
-
Methods inherited from class jakarta.faces.component.UIComponent
encodeAll, getClientId, getCompositeComponentParent, getContainerClientId, getCurrentComponent, getCurrentCompositeComponent, getNamingContainer, getPassThroughAttributes, getResourceBundleMap, getStateHelper, getStateHelper, getTransientStateHelper, getTransientStateHelper, getValueExpression, initialStateMarked, isCompositeComponent, isInView, isVisitable, popComponentFromEL, processEvent, pushComponentToEL, restoreTransientState, saveTransientState, setInView, setValueExpression, visitTree
-
-
-
-
Field Detail
-
COMPONENT_TYPE
public static final String COMPONENT_TYPE
- See Also:
- Constant Field Values
-
COMPONENT_FAMILY
public static final String COMPONENT_FAMILY
- See Also:
- Constant Field Values
-
DEFAULT_HOTKEY
public static final String DEFAULT_HOTKEY
- See Also:
- Constant Field Values
-
-
Method Detail
-
getFamily
public String getFamily()
Description copied from class:UIComponent
Return the identifier of the component family to which this component belongs. This identifier, in conjunction with the value of the
rendererType
property, may be used to select the appropriateRenderer
for this component instance. Note this method should NOT returnnull
- Specified by:
getFamily
in classUIComponent
- Returns:
- the component family (not null).
-
getChildren
public List getChildren()
Description copied from class:UIComponent
Return a mutable
List
representing the childUIComponent
s associated with this component. The returned implementation must support all of the standard and optionalList
methods, plus support the following additional requirements:- The
List
implementation must implement thejava.io.Serializable
interface. - Any attempt to add a
null
must throw a NullPointerException - Any attempt to add an object that does not implement
UIComponent
must throw a ClassCastException. - Whenever a new child component is added, the
parent
property of the child must be set to this component instance. If theparent
property of the child was already non-null, the child must first be removed from its previous parent (where it may have been either a child or a facet). - Whenever an existing child component is removed, the
parent
property of the child must be set tonull
. -
After the child component has been added to the view,
Application.publishEvent(jakarta.faces.context.FacesContext, java.lang.Class<? extends jakarta.faces.event.SystemEvent>, java.lang.Object)
must be called, passingPostAddToViewEvent
.class
as the first argument and the newly added component as the second argument if any the following cases are true.-
FacesContext.getCurrentPhaseId()
returnsPhaseId.RESTORE_VIEW
and partial state saving is enabled. -
FacesContext.isPostback()
returnsfalse
andFacesContext.getCurrentPhaseId()
returns something other thanPhaseId.RESTORE_VIEW
-
- Overrides:
getChildren
in classUIComponentBase
- Returns:
- the list of children.
- The
-
encodeBegin
public void encodeBegin(FacesContext facesContext) throws IOException
Description copied from class:UIComponent
If our
rendered
property istrue
, render the beginning of the current state of thisUIComponent
to the response contained in the specifiedFacesContext
. CallUIComponent.pushComponentToEL(jakarta.faces.context.FacesContext,jakarta.faces.component.UIComponent)
. CallApplication.publishEvent(jakarta.faces.context.FacesContext, java.lang.Class<? extends jakarta.faces.event.SystemEvent>, java.lang.Object)
, passingPreRenderComponentEvent
.class
as the first argument and the component instance to be rendered as the second argument.If a
Renderer
is associated with thisUIComponent
, the actual encoding will be delegated toRenderer.encodeBegin(FacesContext, UIComponent)
.If our
rendered
property isfalse
, callUIComponent.pushComponentToEL(jakarta.faces.context.FacesContext,jakarta.faces.component.UIComponent)
and return immediately.- Overrides:
encodeBegin
in classUIComponentBase
- Parameters:
facesContext
-FacesContext
for the response we are creating- Throws:
IOException
- if an input/output error occurs while rendering
-
debugRequest
public static boolean debugRequest(FacesContext faces)
-
getHotkey
public String getHotkey()
-
setHotkey
public void setHotkey(String hotkey)
-
-