Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.ajax4jsf.renderkit.html
Class AjaxFormRenderer

    java.lang.Object
      javax.faces.render.Renderer
          org.ajax4jsf.renderkit.RendererBase
              org.ajax4jsf.renderkit.HeaderResourcesRendererBase
                  org.ajax4jsf.renderkit.AjaxComponentRendererBase
                      org.ajax4jsf.renderkit.html.AjaxFormRenderer

All Implemented Interfaces:
  org.ajax4jsf.renderkit.ChameleonRenderer, org.ajax4jsf.renderkit.HeaderResourceProducer, org.ajax4jsf.renderkit.HeaderResourceProducer2, org.ajax4jsf.resource.ResourceProduser

    public class AjaxFormRenderer

extends org.ajax4jsf.renderkit.AjaxComponentRendererBase

Author:
  shura

Field Summary
`static java.lang.String` | `AJAX_FORM_FUNCTION_NAME`
`static java.lang.String` | `CONTENT_TYPE_IS_XHTML`
`static java.lang.String` | `FORM_CLEAR_FUNCTION_NAME`
`static java.lang.String` | `FORM_SUBMIT_FUNCTION_NAME`
`static java.lang.String` | `HIDDEN_FIELD_SUFFIX`

Fields inherited from class org.ajax4jsf.renderkit.RendererBase
`JAVASCRIPT_NAMESPACE`

Constructor Summary
`AjaxFormRenderer()`

Method Summary
`protected void` | `doDecode(javax.faces.context.FacesContext context, javax.faces.component.UIComponent component)`
`protected void` | `doEncodeBegin(javax.faces.context.ResponseWriter writer, javax.faces.context.FacesContext context, javax.faces.component.UIComponent component)`
`protected void` | `doEncodeEnd(javax.faces.context.ResponseWriter writer, javax.faces.context.FacesContext context, javax.faces.component.UIComponent component)`
`protected org.ajax4jsf.resource.InternetResource[]` | `getAdditionalScripts()`
`java.lang.String` | `getClearHiddenCommandFormParamsFunctionName(java.lang.String formName)` Prefixes the given String with "clear_" and removes special characters
`protected java.lang.Class` | `getComponentClass()`
`void` | `renderAjaxFormSetupScript(javax.faces.context.ResponseWriter writer, java.lang.String formName)`
`void` | `renderClearHiddenCommandFormParamsFunction(javax.faces.context.ResponseWriter writer, java.lang.String formName, java.util.Set dummyFormParams, java.lang.String formTarget)` Render the javascript function that is called on a click on a commandLink to clear the hidden inputs.
`void` | `renderHiddenCommandFormParams(javax.faces.context.ResponseWriter writer, java.util.Set formParams)`
`void` | `renderHiddenInputField(javax.faces.context.ResponseWriter writer, java.lang.Object name, java.lang.Object value)`

Methods inherited from class org.ajax4jsf.renderkit.AjaxComponentRendererBase
`getScripts`

Methods inherited from class org.ajax4jsf.renderkit.HeaderResourcesRendererBase
`encodeResourcesArray, encodeToHead, getHeaderScripts, getHeaderStyles, getStyles`

Methods inherited from class org.ajax4jsf.renderkit.RendererBase
`addResource, decode, doEncodeChildren, encodeBegin, encodeChildren, encodeEnd, getResource, getSkin, getUtils, preDecode, preEncodeBegin, renderChild, renderChildren`

Methods inherited from class javax.faces.render.Renderer
`convertClientId, getConvertedValue, getRendersChildren`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.ajax4jsf.renderkit.HeaderResourceProducer2
`encodeToHead`

Field Detail

### FORM_SUBMIT_FUNCTION_NAME

    public static final java.lang.String FORM_SUBMIT_FUNCTION_NAME

See Also:
  Constant Field Values

### FORM_CLEAR_FUNCTION_NAME

    public static final java.lang.String FORM_CLEAR_FUNCTION_NAME

See Also:
  Constant Field Values

### CONTENT_TYPE_IS_XHTML

    public static final java.lang.String CONTENT_TYPE_IS_XHTML

See Also:
  Constant Field Values

### HIDDEN_FIELD_SUFFIX

    public static final java.lang.String HIDDEN_FIELD_SUFFIX

See Also:
  Constant Field Values

### AJAX_FORM_FUNCTION_NAME

    public static final java.lang.String AJAX_FORM_FUNCTION_NAME

See Also:
  Constant Field Values

Constructor Detail

### AjaxFormRenderer

    public AjaxFormRenderer()

Method Detail

### doDecode

    protected void doDecode(javax.faces.context.FacesContext context,
                            javax.faces.component.UIComponent component)

  Overrides:
    `doDecode` in class `org.ajax4jsf.renderkit.RendererBase`

### getAdditionalScripts

    protected org.ajax4jsf.resource.InternetResource[] getAdditionalScripts()

  Overrides:
    `getAdditionalScripts` in class `org.ajax4jsf.renderkit.AjaxComponentRendererBase`

### doEncodeBegin

    protected void doEncodeBegin(javax.faces.context.ResponseWriter writer,
                                 javax.faces.context.FacesContext context,
                                 javax.faces.component.UIComponent component)
                          throws java.io.IOException

  Overrides:
    `doEncodeBegin` in class `org.ajax4jsf.renderkit.RendererBase`
  Throws:
    `java.io.IOException`

### doEncodeEnd

    protected void doEncodeEnd(javax.faces.context.ResponseWriter writer,
                               javax.faces.context.FacesContext context,
                               javax.faces.component.UIComponent component)
                        throws java.io.IOException

  Overrides:
    `doEncodeEnd` in class `org.ajax4jsf.renderkit.RendererBase`
  Throws:
    `java.io.IOException`

### getComponentClass

    protected java.lang.Class getComponentClass()

  Specified by:
    `getComponentClass` in class `org.ajax4jsf.renderkit.RendererBase`

### renderHiddenCommandFormParams

    public void renderHiddenCommandFormParams(javax.faces.context.ResponseWriter writer,
                                              java.util.Set formParams)
                                       throws java.io.IOException

  Throws:
    `java.io.IOException`

### renderHiddenInputField

    public void renderHiddenInputField(javax.faces.context.ResponseWriter writer,
                                       java.lang.Object name,
                                       java.lang.Object value)
                                throws java.io.IOException

  Throws:
    `java.io.IOException`

### renderAjaxFormSetupScript

    public void renderAjaxFormSetupScript(javax.faces.context.ResponseWriter writer,
                                          java.lang.String formName)
                                   throws java.io.IOException

  Throws:
    `java.io.IOException`

### renderClearHiddenCommandFormParamsFunction

    public void renderClearHiddenCommandFormParamsFunction(javax.faces.context.ResponseWriter writer,
                                                           java.lang.String formName,
                                                           java.util.Set dummyFormParams,
                                                           java.lang.String formTarget)
                                                    throws java.io.IOException

  Render the javascript function that is called on a click on a commandLink to clear the hidden inputs. This is necessary because on a browser back, each hidden input still has it's old value (browser cache!) and therefore a new submit would cause the according action once more!

  Parameters:
    `writer` -
    `formName` -
    `dummyFormParams` -
    `formTarget` -
  Throws:
    `java.io.IOException`

### getClearHiddenCommandFormParamsFunctionName

    public java.lang.String getClearHiddenCommandFormParamsFunctionName(java.lang.String formName)

  Prefixes the given String with "clear_" and removes special characters

  Parameters:
    `formName` -
  Returns:
    String

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008. All Rights Reserved.