|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.faces.component.UIComponent
javax.faces.component.UIComponentBase
javax.faces.component.UIViewRoot
public class UIViewRoot
Creates a JSF View, which is a container that holds all of the components that are part of the view.
Unless otherwise specified, all attributes accept static values or EL expressions.
See Javadoc of JSF Specification
Field Summary | |
---|---|
static java.lang.String |
COMPONENT_FAMILY
|
static java.lang.String |
COMPONENT_TYPE
|
static java.lang.String |
UNIQUE_ID_PREFIX
|
Constructor Summary | |
---|---|
UIViewRoot()
|
Method Summary | |
---|---|
java.lang.String |
createUniqueId()
Provides a unique id for this component instance. |
void |
encodeBegin(FacesContext context)
|
java.lang.String |
getClientId(FacesContext context)
DO NOT USE. |
java.lang.String |
getFamily()
|
java.lang.String |
getId()
An identifier for this particular component instance within a component view. |
java.util.Locale |
getLocale()
The locale of this view. |
java.lang.String |
getRenderKitId()
Defines what renderkit should be used to render this view. |
java.lang.String |
getViewId()
|
boolean |
isRendered()
A boolean value that indicates whether this component should be rendered. |
void |
processApplication(FacesContext context)
|
void |
processDecodes(FacesContext context)
|
void |
processUpdates(FacesContext context)
This isn't an input component, so just pass on the processUpdates call to child components and facets that might be input components. |
void |
processValidators(FacesContext context)
|
void |
queueEvent(FacesEvent event)
|
void |
restoreState(FacesContext context,
java.lang.Object state)
Invoked in the "restore view" phase, this initialises this object's members from the values saved previously into the provided state object. |
java.lang.Object |
saveState(FacesContext context)
Invoked after the render phase has completed, this method returns an object which can be passed to the restoreState of some other instance of UIComponentBase to reset that object's state to the same values as this object currently has. |
void |
setId(java.lang.String id)
DO NOT USE. |
void |
setLocale(java.util.Locale locale)
|
void |
setRendered(boolean state)
DO NOT USE. |
void |
setRenderKitId(java.lang.String renderKitId)
|
void |
setViewId(java.lang.String viewId)
|
Methods inherited from class javax.faces.component.UIComponentBase |
---|
addFacesListener, broadcast, decode, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getFacesContext, getFacesListeners, getFacet, getFacets, getFacetsAndChildren, getParent, getRenderer, getRendererType, getRendersChildren, getValueBinding, isTransient, processRestoreState, processSaveState, removeFacesListener, restoreAttachedState, saveAttachedState, setParent, setRendererType, setTransient, setValueBinding |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String COMPONENT_TYPE
public static final java.lang.String COMPONENT_FAMILY
public static final java.lang.String UNIQUE_ID_PREFIX
Constructor Detail |
---|
public UIViewRoot()
Method Detail |
---|
public java.lang.String getViewId()
public void setViewId(java.lang.String viewId)
public void queueEvent(FacesEvent event)
queueEvent
in class UIComponentBase
public void processDecodes(FacesContext context)
processDecodes
in class UIComponentBase
public void processValidators(FacesContext context)
processValidators
in class UIComponentBase
public void processUpdates(FacesContext context)
UIComponentBase
Components that were never rendered can't possibly be receiving update data (no corresponding fields were ever put into the response) so if this component is not rendered then this method does not invoke processUpdates on its children.
processUpdates
in class UIComponentBase
public void processApplication(FacesContext context)
public void encodeBegin(FacesContext context) throws java.io.IOException
encodeBegin
in class UIComponentBase
java.io.IOException
public java.lang.String createUniqueId()
public java.util.Locale getLocale()
public void setLocale(java.util.Locale locale)
public java.lang.String getFamily()
getFamily
in class UIComponent
public java.lang.String getRenderKitId()
Note that in JSF1.1 this property cannot be set via the f:view tag (this is possible in JSF1.2).
public void setRenderKitId(java.lang.String renderKitId)
public void setRendered(boolean state)
Although this class extends a base-class that defines a read/write rendered property, it makes no sense for this particular subclass to support it. Yes, this is broken OO design: direct all complaints to the JSF spec group.
Ideally this method would throw an UnsupportedOperationException when invoked. Unfortunately, the JSF TCK calls this method, so instead we just pass on the call to the default inherited implementation.
setRendered
in class UIComponentBase
public boolean isRendered()
UIComponentBase
isRendered
in class UIComponentBase
public void setId(java.lang.String id)
Although this class extends a base-class that defines a read/write id property, it makes no sense for this particular subclass to support it. The tag library does not export this property for use, but there is no way to "undeclare" a java method. Yes, this is broken OO design: direct all complaints to the JSF spec group.
This property should be disabled (ie throw an exception if invoked). However there are currently several places that call this method (eg during restoreState) so it just does the normal thing for the moment. TODO: fix callers then make this throw an exception.
setId
in class UIComponentBase
public java.lang.String getId()
UIComponentBase
The id must be unique within the scope of the tag's enclosing NamingContainer (eg h:form or f:subview). The id is not necessarily unique across all components in the current view
This value must be a static value, ie not change over the lifetime of a component. It cannot be defined via an EL expression; only a string is permitted.
getId
in class UIComponentBase
public java.lang.String getClientId(FacesContext context)
As this component has no "id" property, it has no clientId property either.
Ideally, this method would just return null when called (or even throw an exception) Unforunately, the TCK invokes it so we just invoke the interited implementation instead.
getClientId
in class UIComponentBase
public java.lang.Object saveState(FacesContext context)
UIComponentBase
saveState
in interface StateHolder
saveState
in class UIComponentBase
public void restoreState(FacesContext context, java.lang.Object state)
UIComponentBase
restoreState
in interface StateHolder
restoreState
in class UIComponentBase
state
- is an object previously returned by
the saveState method of this class.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |