org.ajax4jsf.component.html
Class HtmlAjaxRegion

java.lang.Object
  extended by javax.faces.component.UIComponent
      extended by javax.faces.component.UIComponentBase
          extended by javax.faces.component.UIPanel
              extended by org.ajax4jsf.component.UIAjaxRegion
                  extended by org.ajax4jsf.component.html.HtmlAjaxRegion
All Implemented Interfaces:
javax.faces.component.StateHolder, org.ajax4jsf.component.AjaxContainer, org.ajax4jsf.component.AjaxContainerBase, org.ajax4jsf.event.AjaxSource

public class HtmlAjaxRegion
extends UIAjaxRegion

Component-Type org.ajax4jsf.AjaxRegion Component-Family org.ajax4jsf.AjaxRegion Renderer-Type org.ajax4jsf.components.AjaxRegionRenderer Root view for ajax areas on the page. It must either be a nested tag inside the <body> tag inside of the <html> tag or, if selfRendered="true", it can be in any part of the page. Decode: Obtain the Map from the "requestParameterMap" property of the ExternalContext. If the value in Map for the "AJAXREQUEST" is not null, and equals to value of the "clientId" property of the component, set ajaxRequest property to true, create AjaxEvent around the component, and pass it to the queueEvent() method of the component, which must be an instance of AjaxContainer Rendering : On standart JSF request, insert <script> element with link to Ajax client-side javaScript at start tag position. If performed Ajax request, invoke listeners and render only affected to request components. List of clientId of rendered components set as special response headers and hidden <span> html element. With 'selfRendered' attribute set as "true", render affected components at Invoke Application phase - produce <html><body> elements, render affected components and set responseComplete at FacesContext. In this case, JSP page not rendered. Since, Jstl or other JSP tags must not be used inside <a4jx:region> with immediate flag.


Field Summary
static java.lang.String COMPONENT_FAMILY
           
static java.lang.String COMPONENT_TYPE
           
 
Constructor Summary
HtmlAjaxRegion()
          Constructor to init default renderers
 
Method Summary
 java.lang.String getFamily()
           
 boolean isRenderRegionOnly()
          Flag to disable rendering in AJAX responses content outside of active region.
 void restoreState(javax.faces.context.FacesContext context, java.lang.Object state)
           
 java.lang.Object saveState(javax.faces.context.FacesContext context)
           
 void setRenderRegionOnly(boolean __renderRegionOnly)
          Flag to disable rendering in AJAX responses content outside of active region.
 
Methods inherited from class org.ajax4jsf.component.UIAjaxRegion
addAjaxListener, broadcast, encodeAjax, encodeChildren, getAjaxListener, getAjaxListeners, isImmediate, isSelfRendered, isSubmitted, removeAjaxListener, setAjaxListener, setImmediate, setSelfRendered, setSubmitted
 
Methods inherited from class javax.faces.component.UIComponentBase
addFacesListener, decode, encodeBegin, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getClientId, getFacesContext, getFacesListeners, getFacet, getFacets, getFacetsAndChildren, getId, getParent, getRenderer, getRendererType, getRendersChildren, getValueBinding, isRendered, isTransient, processDecodes, processRestoreState, processSaveState, processUpdates, processValidators, queueEvent, removeFacesListener, restoreAttachedState, saveAttachedState, setId, setParent, setRendered, setRendererType, setTransient, setValueBinding
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COMPONENT_TYPE

public static final java.lang.String COMPONENT_TYPE
See Also:
Constant Field Values

COMPONENT_FAMILY

public static final java.lang.String COMPONENT_FAMILY
See Also:
Constant Field Values
Constructor Detail

HtmlAjaxRegion

public HtmlAjaxRegion()
Constructor to init default renderers

Method Detail

setRenderRegionOnly

public void setRenderRegionOnly(boolean __renderRegionOnly)
Flag to disable rendering in AJAX responses content outside of active region. If this attribute set to "true" , no one of the components outside of region will be included to AJAX response. If set to "false", search for components to include in response will be performed on all tree. Default "false" Setter for renderRegionOnly

Parameters:
renderRegionOnly - - new value

isRenderRegionOnly

public boolean isRenderRegionOnly()
Flag to disable rendering in AJAX responses content outside of active region. If this attribute set to "true" , no one of the components outside of region will be included to AJAX response. If set to "false", search for components to include in response will be performed on all tree. Default "false" Getter for renderRegionOnly

Returns:
renderRegionOnly value from local variable or value bindings

getFamily

public java.lang.String getFamily()
Overrides:
getFamily in class javax.faces.component.UIPanel

saveState

public java.lang.Object saveState(javax.faces.context.FacesContext context)
Specified by:
saveState in interface javax.faces.component.StateHolder
Overrides:
saveState in class UIAjaxRegion

restoreState

public void restoreState(javax.faces.context.FacesContext context,
                         java.lang.Object state)
Specified by:
restoreState in interface javax.faces.component.StateHolder
Overrides:
restoreState in class UIAjaxRegion


Copyright © 2007. All Rights Reserved.