| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.faces.view.facelets.TagHandler
javax.faces.view.facelets.MetaTagHandler
javax.faces.view.facelets.DelegatingMetaTagHandler
javax.faces.view.facelets.ComponentHandler
public class ComponentHandler
Public base class for markup element
 instances that map to UIComponent instances in the view.
The implementation must guarantee that the apply()
 method is overridden and takes the following actions, in this order.
 These actions must only happen the first time this facelet is applied
 for each user.  Subsequent applications must take no action.
The UIComponent represented by this
          element is created with the appropriate
          Application.createComponent() method.  
Each attribute specified in the markup is correctly applied to the component instance, as specified in the VDLDocs for this element.
If project stage is #ProjectStage.Development,
      Put the Location for this
          element into the component attribute Map under
          the key given by the value of the symbolic constant UIComponent.VIEW_LOCATION_KEY.
          
Set the id of the component.  If the id is specified
          manually by the page author, that value must be set as the id.
          Otherwise, the closest ancestor component that is an instance
          of UniqueIdVendor must be
          located and its UniqueIdVendor.createUniqueId(javax.faces.context.FacesContext, java.lang.String) method
          must be called to derive the id.  If no such instance can be
          found, call UIViewRoot.createUniqueId() to derive the
          id.
The rendererType property of the component is set properly.
UIComponent#pushComponentToEL is called on the
          newly created component.
The next handler in the facelet chain is applied. This will cause the component to be populated with children.
The component is added to its parent in the view.
UIComponent#popComponentFromEL is called on the
          newly created component.
Call UIComponent#markInitialState.
          
| Field Summary | 
|---|
| Fields inherited from class javax.faces.view.facelets.DelegatingMetaTagHandler | 
|---|
| delegateFactory | 
| Fields inherited from class javax.faces.view.facelets.TagHandler | 
|---|
| nextHandler, tag, tagId | 
| Constructor Summary | |
|---|---|
| ComponentHandler(ComponentConfig config)Leverage the  | |
| Method Summary | |
|---|---|
|  ComponentConfig | getComponentConfig() | 
| protected  TagHandlerDelegate | getTagHandlerDelegate() | 
| static boolean | isNew(UIComponent component)Determine if the passed component is not null and if it's new to the tree. | 
|  void | onComponentCreated(FaceletContext ctx,
                   UIComponent c,
                   UIComponent parent)This method is guaranteed to be called after the component has been created but before it has been populated with children. | 
|  void | onComponentPopulated(FaceletContext ctx,
                     UIComponent c,
                     UIComponent parent)This method is guaranteed to be called after the component has been populated with children. | 
| Methods inherited from class javax.faces.view.facelets.DelegatingMetaTagHandler | 
|---|
| apply, applyNextHandler, createMetaRuleset, getBinding, getTag, getTagAttribute, getTagId, isDisabled, setAttributes | 
| Methods inherited from class javax.faces.view.facelets.TagHandler | 
|---|
| getAttribute, getRequiredAttribute, toString | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Constructor Detail | 
|---|
public ComponentHandler(ComponentConfig config)
Leverage the TagHandlerDelegateFactory provided by the implementation to create
 an instance of TagHandlerDelegate designed for use with
 ComponentHandler.
| Method Detail | 
|---|
protected TagHandlerDelegate getTagHandlerDelegate()
getTagHandlerDelegate in class DelegatingMetaTagHandlerpublic ComponentConfig getComponentConfig()
public void onComponentCreated(FaceletContext ctx,
                               UIComponent c,
                               UIComponent parent)
This method is guaranteed to be called after the component has been created but before it has been populated with children.
ctx - the FaceletContext for this view executionc - the UIComponent that has just been created.parent - the parent UIComponent of the
 component represented by this element instance.
public void onComponentPopulated(FaceletContext ctx,
                                 UIComponent c,
                                 UIComponent parent)
This method is guaranteed to be called after the component has been populated with children.
ctx - the FaceletContext for this view executionc - the UIComponent that has just been
 populated with children.parent - the parent UIComponent of the
 component represented by this element instance.public static boolean isNew(UIComponent component)
Determine if the passed component is not null and if it's new to the tree. This operation can be used for determining if attributes should be wired to the component.
component - the component you wish to modify| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright © 2009-2011, Oracle Corporation and/or its affiliates. All Rights Reserved. Use is subject to license terms.
Generated on 10-February-2011 12:41