org.apache.myfaces.custom.inputAjax
Class AbstractHtmlSelectManyCheckboxAjax

java.lang.Object
  extended by javax.faces.component.UIComponent
      extended by javax.faces.component.UIComponentBase
          extended by javax.faces.component.UIOutput
              extended by javax.faces.component.UIInput
                  extended by javax.faces.component.UISelectMany
                      extended by javax.faces.component.html.HtmlSelectManyCheckbox
                          extended by org.apache.myfaces.component.html.ext.AbstractHtmlSelectManyCheckbox
                              extended by org.apache.myfaces.component.html.ext.HtmlSelectManyCheckbox
                                  extended by org.apache.myfaces.custom.inputAjax.AbstractHtmlSelectManyCheckboxAjax
All Implemented Interfaces:
javax.faces.component.EditableValueHolder, javax.faces.component.StateHolder, javax.faces.component.ValueHolder, org.apache.myfaces.component.AltProperty, org.apache.myfaces.component.DataProperties, org.apache.myfaces.component.DisplayValueOnlyAware, org.apache.myfaces.component.EscapeAware, org.apache.myfaces.component.ForceIdAware, org.apache.myfaces.component.UserRoleAware, AjaxCallbacks, AjaxComponent, DeprecatedAjaxComponent, org.apache.myfaces.custom.ExtendedComponentBase, org.apache.myfaces.shared_tomahawk.component.DisplayValueOnlyCapable, org.apache.myfaces.shared_tomahawk.component.EscapeCapable
Direct Known Subclasses:
HtmlSelectManyCheckboxAjax

public abstract class AbstractHtmlSelectManyCheckboxAjax
extends org.apache.myfaces.component.html.ext.HtmlSelectManyCheckbox
implements DeprecatedAjaxComponent, AjaxCallbacks

Extends standard selectManyCheckbox allowing for dynamic ajax submitting. Current limitations - Bound value must be a Collection of Strings!

Version:
$Revision: 663481 $ $Date: 2008-06-05 02:00:34 -0500 (Thu, 05 Jun 2008) $
Author:
Travis Reeder (latest modification by $Author: lu4242 $)

Field Summary
static java.lang.String COMPONENT_TYPE
           
static java.lang.String DEFAULT_RENDERER_TYPE
           
 
Fields inherited from class org.apache.myfaces.component.html.ext.HtmlSelectManyCheckbox
COMPONENT_FAMILY
 
Fields inherited from class javax.faces.component.UISelectMany
INVALID_MESSAGE_ID
 
Fields inherited from class javax.faces.component.UIInput
CONVERSION_MESSAGE_ID, REQUIRED_MESSAGE_ID
 
Fields inherited from interface org.apache.myfaces.component.UserRoleAware
ENABLED_ON_USER_ROLE_ATTR, VISIBLE_ON_USER_ROLE_ATTR
 
Fields inherited from interface org.apache.myfaces.shared_tomahawk.component.DisplayValueOnlyCapable
DISPLAY_VALUE_ONLY_ATTR, DISPLAY_VALUE_ONLY_STYLE_ATTR, DISPLAY_VALUE_ONLY_STYLE_CLASS_ATTR
 
Constructor Summary
AbstractHtmlSelectManyCheckboxAjax()
           
 
Method Summary
 void decodeAjax(javax.faces.context.FacesContext context)
          Decode ajax request and apply value changes
 void encodeAjax(javax.faces.context.FacesContext context)
           
abstract  java.lang.String getOnFailure()
          Javascript method to call on failed ajax update
abstract  java.lang.String getOnStart()
          Javascript method to call on start of ajax update
abstract  java.lang.String getOnSuccess()
          Javascript method to call on successful ajax update
 void updateChosenValue(java.util.Collection c, java.lang.String elname, java.lang.String elvalue, boolean checked)
          Will find the chosen value in the chosenValues list and update set or unset accordingly.
 
Methods inherited from class org.apache.myfaces.component.html.ext.HtmlSelectManyCheckbox
getAlt, getDatafld, getDataformatas, getDatasrc, getDisplayValueOnly, getDisplayValueOnlyStyle, getDisplayValueOnlyStyleClass, getEnabledOnUserRole, getFamily, getLayoutWidth, getVisibleOnUserRole, isEscape, isForceId, isForceIdIndex, restoreState, saveState, setAlt, setDatafld, setDataformatas, setDatasrc, setDisplayValueOnly, setDisplayValueOnlyStyle, setDisplayValueOnlyStyleClass, setEnabledOnUserRole, setEscape, setForceId, setForceIdIndex, setLayoutWidth, setVisibleOnUserRole
 
Methods inherited from class org.apache.myfaces.component.html.ext.AbstractHtmlSelectManyCheckbox
getClientId, isDisplayValueOnly, isRendered, isSetDisplayValueOnly, setDisplayValueOnly
 
Methods inherited from class javax.faces.component.html.HtmlSelectManyCheckbox
getAccesskey, getBorder, getDir, getDisabledClass, getEnabledClass, getLang, getLayout, getOnblur, getOnchange, getOnclick, getOndblclick, getOnfocus, getOnkeydown, getOnkeypress, getOnkeyup, getOnmousedown, getOnmousemove, getOnmouseout, getOnmouseover, getOnmouseup, getOnselect, getStyle, getStyleClass, getTabindex, getTitle, isDisabled, isReadonly, setAccesskey, setBorder, setDir, setDisabled, setDisabledClass, setEnabledClass, setLang, setLayout, setOnblur, setOnchange, setOnclick, setOndblclick, setOnfocus, setOnkeydown, setOnkeypress, setOnkeyup, setOnmousedown, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnselect, setReadonly, setStyle, setStyleClass, setTabindex, setTitle
 
Methods inherited from class javax.faces.component.UISelectMany
compareValues, getConvertedValue, getSelectedValues, getValueBinding, setSelectedValues, setValueBinding, validate, validateValue
 
Methods inherited from class javax.faces.component.UIInput
addValidator, addValueChangeListener, broadcast, decode, getSubmittedValue, getValidator, getValidators, getValue, getValueChangeListener, getValueChangeListeners, isImmediate, isLocalValueSet, isRequired, isValid, processDecodes, processUpdates, processValidators, removeValidator, removeValueChangeListener, setImmediate, setLocalValueSet, setRequired, setSubmittedValue, setValid, setValidator, setValue, setValueChangeListener, updateModel
 
Methods inherited from class javax.faces.component.UIOutput
getConverter, getLocalValue, setConverter
 
Methods inherited from class javax.faces.component.UIComponentBase
addFacesListener, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getFacesContext, getFacesListeners, getFacet, getFacets, getFacetsAndChildren, getId, getParent, getRenderer, getRendererType, getRendersChildren, isTransient, processRestoreState, processSaveState, queueEvent, removeFacesListener, restoreAttachedState, saveAttachedState, setId, setParent, setRendered, setRendererType, setTransient
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.myfaces.custom.ajax.AjaxCallbacks
setOnFailure, setOnStart, setOnSuccess
 
Methods inherited from interface javax.faces.component.ValueHolder
getConverter, getLocalValue, setConverter
 

Field Detail

COMPONENT_TYPE

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

DEFAULT_RENDERER_TYPE

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

AbstractHtmlSelectManyCheckboxAjax

public AbstractHtmlSelectManyCheckboxAjax()
Method Detail

decodeAjax

public void decodeAjax(javax.faces.context.FacesContext context)
Decode ajax request and apply value changes

Specified by:
decodeAjax in interface AjaxComponent
Parameters:
context -

updateChosenValue

public void updateChosenValue(java.util.Collection c,
                              java.lang.String elname,
                              java.lang.String elvalue,
                              boolean checked)
Will find the chosen value in the chosenValues list and update set or unset accordingly.

Parameters:
c -
elname -
elvalue -
checked -

encodeAjax

public void encodeAjax(javax.faces.context.FacesContext context)
                throws java.io.IOException
Specified by:
encodeAjax in interface AjaxComponent
Throws:
java.io.IOException

getOnSuccess

public abstract java.lang.String getOnSuccess()
Javascript method to call on successful ajax update

Specified by:
getOnSuccess in interface AjaxCallbacks

getOnFailure

public abstract java.lang.String getOnFailure()
Javascript method to call on failed ajax update

Specified by:
getOnFailure in interface AjaxCallbacks

getOnStart

public abstract java.lang.String getOnStart()
Javascript method to call on start of ajax update

Specified by:
getOnStart in interface AjaxCallbacks


Copyright © 2011 The Apache Software Foundation. All Rights Reserved.