org.richfaces.context

## Class ExtendedPartialViewContextImpl

- java.lang.Object
- - javax.faces.context.PartialViewContext
  - - org.richfaces.context.ExtendedPartialViewContext
    - - org.richfaces.context.ExtendedPartialViewContextImpl

-     public class ExtendedPartialViewContextImpl
      extends org.richfaces.context.ExtendedPartialViewContext

  The RichFaces custom version of PartialViewContext

  Unfortunately, it is not possible to get the parameters value from inside PartialViewContextFactory (due to encoding issues), so a RichFaces implementation wrapping the original context is created. It either delegates calls to the wrapped context (if the request does not include ‘org.richfaces.ajax.component’ parameter), or it executes the necessary logic (for RichFaces-initiated requests). The detectContextMode() method is responsible for this. Due to this issue we have to re-implement big portion of PartialViewContext functionality in our class.

  Important differences of RichFaces implementation:

  - Values are resolved in runtime by visiting the request activator component and evaluating attributes
  - Usage of extended visit contexts in order to support meta-components processing
  - Support for auto-updateable Ajax components
  - Support for Ajax extensions like passing data to the client
  Author:
    Nick Belaevski

- - ### Field Summary

    - ### Fields inherited from class javax.faces.context.PartialViewContext

      `ALL_PARTIAL_PHASE_CLIENT_IDS, PARTIAL_EXECUTE_PARAM_NAME, PARTIAL_RENDER_PARAM_NAME`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ExtendedPartialViewContextImpl(javax.faces.context.PartialViewContext wrappedViewContext, javax.faces.context.FacesContext facesContext)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `addImplicitExecuteIds(Collection<String> ids)`
    `protected void` | `addImplicitRenderIds(Collection<String> ids, boolean limitRender)`
    `protected void` | `addJavaScriptServicePageScripts(javax.faces.context.FacesContext context)`
    `protected org.richfaces.context.ExtendedPartialViewContextImpl.ContextMode` | `detectContextMode()`
    `protected void` | `executeComponents(javax.faces.event.PhaseId phaseId, Collection<String> executeIds)`
    `Collection<String>` | `getExecuteIds()`
    `javax.faces.context.PartialResponseWriter` | `getPartialResponseWriter()`
    `Collection<String>` | `getRenderIds()`
    `boolean` | `isAjaxRequest()`
    `boolean` | `isExecuteAll()`
    `boolean` | `isPartialRequest()`
    `boolean` | `isRenderAll()`
    `void` | `processPartial(javax.faces.event.PhaseId phaseId)`
    `protected void` | `processPartialExecutePhase(javax.faces.event.PhaseId phaseId)`
    `protected void` | `processPartialRenderPhase()`
    `void` | `release()`
    `protected void` | `renderExtensions(javax.faces.context.FacesContext context, javax.faces.component.UIComponent component)`
    `void` | `setPartialRequest(boolean isPartialRequest)`
    `void` | `setRenderAll(boolean isRenderAll)`

    - ### Methods inherited from class org.richfaces.context.ExtendedPartialViewContext

      `appendOnbeforedomupdate, appendOncomplete, getFacesContext, getInstance, getOnbeforedomupdate, getOncomplete, getResponseComponentDataMap, getResponseData, isLimitRender, prependOnbeforedomupdate, prependOncomplete, setLimitRender, setResponseData`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ExtendedPartialViewContextImpl

          public ExtendedPartialViewContextImpl(javax.faces.context.PartialViewContext wrappedViewContext,
                                        javax.faces.context.FacesContext facesContext)

  - ### Method Detail

    - #### getExecuteIds

          public Collection<String> getExecuteIds()

      Specified by:
        `getExecuteIds` in class `javax.faces.context.PartialViewContext`

    - #### getRenderIds

          public Collection<String> getRenderIds()

      Specified by:
        `getRenderIds` in class `javax.faces.context.PartialViewContext`

    - #### isAjaxRequest

          public boolean isAjaxRequest()

      Specified by:
        `isAjaxRequest` in class `javax.faces.context.PartialViewContext`

    - #### isPartialRequest

          public boolean isPartialRequest()

      Specified by:
        `isPartialRequest` in class `javax.faces.context.PartialViewContext`

    - #### setPartialRequest

          public void setPartialRequest(boolean isPartialRequest)

      Specified by:
        `setPartialRequest` in class `javax.faces.context.PartialViewContext`

    - #### isExecuteAll

          public boolean isExecuteAll()

      Specified by:
        `isExecuteAll` in class `javax.faces.context.PartialViewContext`

    - #### isRenderAll

          public boolean isRenderAll()

      Specified by:
        `isRenderAll` in class `javax.faces.context.PartialViewContext`

    - #### setRenderAll

          public void setRenderAll(boolean isRenderAll)

      Specified by:
        `setRenderAll` in class `javax.faces.context.PartialViewContext`

    - #### getPartialResponseWriter

          public javax.faces.context.PartialResponseWriter getPartialResponseWriter()

      Specified by:
        `getPartialResponseWriter` in class `javax.faces.context.PartialViewContext`

    - #### processPartial

          public void processPartial(javax.faces.event.PhaseId phaseId)

      Specified by:
        `processPartial` in class `javax.faces.context.PartialViewContext`

    - #### processPartialExecutePhase

          protected void processPartialExecutePhase(javax.faces.event.PhaseId phaseId)

    - #### executeComponents

          protected void executeComponents(javax.faces.event.PhaseId phaseId,
                               Collection<String> executeIds)

    - #### processPartialRenderPhase

          protected void processPartialRenderPhase()

    - #### release

          public void release()

      Overrides:
        `release` in class `org.richfaces.context.ExtendedPartialViewContext`

    - #### addImplicitExecuteIds

          protected void addImplicitExecuteIds(Collection<String> ids)

    - #### addImplicitRenderIds

          protected void addImplicitRenderIds(Collection<String> ids,
                                  boolean limitRender)

    - #### addJavaScriptServicePageScripts

          protected void addJavaScriptServicePageScripts(javax.faces.context.FacesContext context)

    - #### renderExtensions

          protected void renderExtensions(javax.faces.context.FacesContext context,
                              javax.faces.component.UIComponent component)
                                   throws IOException

      Throws:
        `IOException`

    - #### detectContextMode

          protected org.richfaces.context.ExtendedPartialViewContextImpl.ContextMode detectContextMode()

Copyright © 2014 JBoss by Red Hat. All Rights Reserved.