org.apache.myfaces.trinidadinternal.renderkit.core.xhtml
Class SimpleSelectManyRenderer
java.lang.Object
javax.faces.render.Renderer
org.apache.myfaces.trinidad.render.CoreRenderer
org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.XhtmlRenderer
org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.ValueRenderer
org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.EditableValueRenderer
org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.FormElementRenderer
org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.FormInputRenderer
org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.SimpleSelectManyRenderer
- All Implemented Interfaces:
- java.lang.Cloneable, org.apache.myfaces.trinidad.render.TypedRenderer
- Direct Known Subclasses:
- SelectManyShuttleRenderer, SimpleSelectManyCheckboxRenderer, SimpleSelectManyListboxRenderer
public abstract class SimpleSelectManyRenderer
- extends FormInputRenderer
Renderer for SelectMany listboxes.
| Fields inherited from class org.apache.myfaces.trinidad.render.CoreRenderer |
CHAR_UNDEFINED, NO_CHILD_INDEX |
|
Method Summary |
protected void |
encodeAllAsElement(javax.faces.context.FacesContext context,
org.apache.myfaces.trinidad.context.RenderingContext rc,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean)
|
protected abstract void |
encodeElementContent(javax.faces.context.FacesContext context,
org.apache.myfaces.trinidad.context.RenderingContext rc,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean,
java.util.List<javax.faces.model.SelectItem> selectItems,
int[] selectedIndices,
javax.faces.convert.Converter converter,
boolean valuePassThru)
Encode the content of a SelectMany component. |
protected void |
findTypeConstants(org.apache.myfaces.trinidad.bean.FacesBean.Type type)
|
java.lang.Object |
getConvertedValue(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent component,
java.lang.Object submittedValue)
Support the following types of values:
Object[] (that contains strings),
String[], List (that contains strings). |
protected javax.faces.convert.Converter |
getDefaultConverter(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent copmonent,
org.apache.myfaces.trinidad.bean.FacesBean bean)
Override to return a Converter for the items in the value,
not the value itself. |
protected java.lang.String |
getRequiredMessageKey()
|
protected int[] |
getSelectedIndices(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean,
java.util.List<javax.faces.model.SelectItem> selectItems,
javax.faces.convert.Converter converter,
boolean valuePassThru)
Return all the selected indices. |
protected java.util.List<javax.faces.model.SelectItem> |
getSelectItems(javax.faces.component.UIComponent component,
javax.faces.convert.Converter converter)
|
protected java.util.List<javax.faces.model.SelectItem> |
getSelectItems(javax.faces.component.UIComponent component,
javax.faces.convert.Converter converter,
boolean filteredItems)
|
protected java.lang.Object |
getSubmittedValue(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent component,
java.lang.String clientId)
|
protected boolean |
getValuePassThru(javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean)
|
protected boolean |
isReorderable()
Returns true if the renderer cares about order. |
protected void |
renderBetweenNonElements(javax.faces.context.FacesContext context,
org.apache.myfaces.trinidad.context.RenderingContext rc,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean)
|
protected void |
renderNonElementContent(javax.faces.context.FacesContext context,
org.apache.myfaces.trinidad.context.RenderingContext rc,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean)
|
| Methods inherited from class org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.FormElementRenderer |
detectAutoSubmit, encodeAll, encodeAllAsNonElement, getContentStyle, getDefaultStyleClass, getHiddenLabel, getLabel, getOnblur, getOnchange, getOnfocus, getRendersChildren, isAutoSubmit, isHiddenLabelRequired, renderAsElement, renderEventHandlers, renderFormEventHandlers, renderReadOnlyAsElement, renderShortDescAsHiddenLabel |
| Methods inherited from class org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.EditableValueRenderer |
addOnSubmitConverterValidators, decode, getConvertedString, getDisabled, getReadOnly, getRequired, getSubmittedValue, getValidators, isImmediate, shouldRenderId, wasSubmitted |
| Methods inherited from class org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.XhtmlRenderer |
canSkipRendering, canSkipRendering, cloneWithType, getAbsoluteImageUri, getBaseImageUri, getInlineStyle, getOnclick, getOndblclick, getOnkeydown, getOnkeypress, getOnkeyup, getOnmousedown, getOnmousemove, getOnmouseout, getOnmouseover, getOnmouseup, getPartialTriggers, getShortDesc, getStyleClass, renderAllAttributes, renderDecorativeIcon, renderDecorativeIcon, renderFormattedText, renderHAlign, renderInlineStyle, renderInlineStyleAttribute, renderPossiblyFormattedText, renderScriptDeferAttribute, renderScriptTypeAttribute, renderShortDescAttribute, renderSpacer, renderStyleAttributes, renderStyleAttributes, renderSubmitButtonNonJSBrowser, renderTransparent, renderVerticalSpacer, resolveProperty, resolveProperty, skipDecode, supportsAccessKeys, supportsAdvancedForms, supportsAutoCompleteFormElements, supportsDisabledFormElements, supportsEditing, supportsIntrinsicEvents, supportsNarrowScreen, supportsNavigation, supportsOnClickOnImgInput, supportsReadonlyFormElements, supportsScripting, supportsSeparateWindow, supportsStyleAttributes, supportsTarget, supportsTextPresentation |
| Methods inherited from class org.apache.myfaces.trinidad.render.CoreRenderer |
afterEncode, beforeEncode, decode, decodeBehaviors, delegateRenderer, delegateRendererBegin, delegateRendererEnd, encodeAllChildren, encodeBegin, encodeBegin, encodeChild, encodeChildren, encodeComponentResources, encodeEnd, encodeEnd, getBehaviorParameters, getClientId, getFacesBean, getFacet, getNextRenderedChildIndex, getRenderedChildCount, getRenderedFacetsAndChildren, getRenderingProperty, hasRenderedChildren, isDesktop, isGecko, isGenericPDA, isIE, isInaccessibleMode, isIPhone, isKonqueror, isNokiaS60, isOpera, isPDA, isScreenReaderMode, isWebKit, partialEncodeVisit, renderEncodedActionURI, renderEncodedResourceURI, renderStyleClass, renderStyleClasses, setRenderingProperty, setupChildrenEncodingContext, setupEncodingContext, setupEncodingContext, tearDownChildrenEncodingContext, tearDownEncodingContext, tearDownEncodingContext, toActionUri, toChar, toInt, toLong, toResourceUri, toString, toUri, visitChildrenForEncoding |
| Methods inherited from class javax.faces.render.Renderer |
convertClientId |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SimpleSelectManyRenderer
public SimpleSelectManyRenderer(org.apache.myfaces.trinidad.bean.FacesBean.Type type)
findTypeConstants
protected void findTypeConstants(org.apache.myfaces.trinidad.bean.FacesBean.Type type)
- Overrides:
findTypeConstants in class FormInputRenderer
getConvertedValue
public java.lang.Object getConvertedValue(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent component,
java.lang.Object submittedValue)
throws javax.faces.convert.ConverterException
- Support the following types of values:
Object[] (that contains strings),
String[], List (that contains strings). (selected values)
- Overrides:
getConvertedValue in class EditableValueRenderer
- Parameters:
context - the FacesContextcomponent - the component
- Throws:
javax.faces.convert.ConverterException
getSubmittedValue
protected java.lang.Object getSubmittedValue(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent component,
java.lang.String clientId)
- Overrides:
getSubmittedValue in class FormElementRenderer
getDefaultConverter
protected javax.faces.convert.Converter getDefaultConverter(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent copmonent,
org.apache.myfaces.trinidad.bean.FacesBean bean)
- Override to return a Converter for the items in the value,
not the value itself.
- Overrides:
getDefaultConverter in class ValueRenderer
getSelectItems
protected java.util.List<javax.faces.model.SelectItem> getSelectItems(javax.faces.component.UIComponent component,
javax.faces.convert.Converter converter)
getSelectItems
protected java.util.List<javax.faces.model.SelectItem> getSelectItems(javax.faces.component.UIComponent component,
javax.faces.convert.Converter converter,
boolean filteredItems)
encodeAllAsElement
protected void encodeAllAsElement(javax.faces.context.FacesContext context,
org.apache.myfaces.trinidad.context.RenderingContext rc,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean)
throws java.io.IOException
- Overrides:
encodeAllAsElement in class FormElementRenderer
- Throws:
java.io.IOException
encodeElementContent
protected abstract void encodeElementContent(javax.faces.context.FacesContext context,
org.apache.myfaces.trinidad.context.RenderingContext rc,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean,
java.util.List<javax.faces.model.SelectItem> selectItems,
int[] selectedIndices,
javax.faces.convert.Converter converter,
boolean valuePassThru)
throws java.io.IOException
- Encode the content of a SelectMany component.
- Parameters:
context - the FacesContextrc - the AdfRenderingContextcomponent - the UIComponentbean - the FacesBeanselectItems - a List of SelectItem instances
- Throws:
java.io.IOException
renderNonElementContent
protected void renderNonElementContent(javax.faces.context.FacesContext context,
org.apache.myfaces.trinidad.context.RenderingContext rc,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean)
throws java.io.IOException
- Overrides:
renderNonElementContent in class FormElementRenderer
- Throws:
java.io.IOException
renderBetweenNonElements
protected void renderBetweenNonElements(javax.faces.context.FacesContext context,
org.apache.myfaces.trinidad.context.RenderingContext rc,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean)
throws java.io.IOException
- Throws:
java.io.IOException
getRequiredMessageKey
protected java.lang.String getRequiredMessageKey()
- Overrides:
getRequiredMessageKey in class EditableValueRenderer
getValuePassThru
protected boolean getValuePassThru(javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean)
isReorderable
protected boolean isReorderable()
- Returns true if the renderer cares about order.
getSelectedIndices
protected int[] getSelectedIndices(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent component,
org.apache.myfaces.trinidad.bean.FacesBean bean,
java.util.List<javax.faces.model.SelectItem> selectItems,
javax.faces.convert.Converter converter,
boolean valuePassThru)
- Return all the selected indices. (There
may be included -1's in case of an error)
The list will be sorted, unless isReorderable()
returns true.
Copyright © 2001-2011 The Apache Software Foundation. All Rights Reserved.