com.bea.portlet.adapter.faces.component.naming
Class NamingContainerComponent

java.lang.Object
  extended by javax.faces.component.UIComponent
      extended by javax.faces.component.UIComponentBase
          extended by com.bea.portlet.adapter.faces.component.naming.NamingContainerComponent
All Implemented Interfaces
NamingContainer, StateHolder

public final class NamingContainerComponent
extends UIComponentBase
implements NamingContainer

Custom JSF component to introduce a NamingContainer in the component tree that is responsible for ensuring that component identifiers in the component tree are unique within a portal page.

Usage

Refer to Usage for usage information.

See Also
Overview

Field Summary
 
Fields inherited from class javax.faces.component.UIComponent
bindings
 
Fields inherited from interface javax.faces.component.NamingContainer
SEPARATOR_CHAR
 
Constructor Summary
NamingContainerComponent()
          Constructor.
 
Method Summary
 String getClientId(javax.faces.context.FacesContext context)
          Get the client ID.
 String getDefaultScopeKey()
          Get the default value for the scope key if the request is not being processed within a facesContent control in a portal.
 String getFamily()
          Get the component family (com.bea.portlet.faces.naming.NamingContainer).
 String getId()
          Get the ID of this component.
 void setDefaultScopeKey(String defaultScopeKey)
          Change the default value for the scope key if the request is not being processed within a facesContent control in a portal.
 void setId(String id)
          Change the ID of this component.
 
Methods inherited from class javax.faces.component.UIComponentBase
addFacesListener, broadcast, decode, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getFacesContext, getFacesListeners, getFacet, getFacetCount, getFacets, getFacetsAndChildren, getParent, getRenderer, getRendererType, getRendersChildren, getValueBinding, invokeOnComponent, isRendered, isTransient, processDecodes, processRestoreState, processSaveState, processUpdates, processValidators, queueEvent, removeFacesListener, restoreAttachedState, restoreState, saveAttachedState, saveState, setParent, setRendered, setRendererType, setTransient, setValueBinding
 
Methods inherited from class javax.faces.component.UIComponent
encodeAll, getContainerClientId, getValueExpression, setValueExpression
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NamingContainerComponent

public NamingContainerComponent()
Constructor.

Method Detail

getDefaultScopeKey

public String getDefaultScopeKey()
Get the default value for the scope key if the request is not being processed within a facesContent control in a portal.

Returns
the default value for the scope key if the request is not being processed within a facesContent control in a portal

setDefaultScopeKey

public void setDefaultScopeKey(String defaultScopeKey)
Change the default value for the scope key if the request is not being processed within a facesContent control in a portal.

Parameters
defaultScopeKey - the default value for the scope key if the request is not being processed within a facesContent control in a portal

getFamily

public String getFamily()
Get the component family (com.bea.portlet.faces.naming.NamingContainer).

Specified by:
getFamily in class UIComponent
Returns
the component family (com.bea.portlet.faces.naming.NamingContainer)

getClientId

public String getClientId(javax.faces.context.FacesContext context)
Get the client ID.

The client ID is constructed from the scope key.

Overrides:
getClientId in class UIComponentBase
Returns
the client ID
See Also
ScopedIdSupport.getScopeKey(FacesContext, String)

getId

public String getId()
Get the ID of this component.

The ID is the scope key.

Overrides:
getId in class UIComponentBase
Returns
the ID (the scope key) of this component
See Also
ScopedIdSupport.getScopeKey(FacesContext, String)

setId

public void setId(String id)
Change the ID of this component.

This method forces the ID of this component to be the scope key. It is not possible to override the ID of this component.

Overrides:
setId in class UIComponentBase
Parameters
id - (ignored) the ID of this component
See Also
ScopedIdSupport.getScopeKey(FacesContext, String)


Copyright © 2011, Oracle. All rights reserved.