org.kuali.rice.krad.uif.control
Class MultiValueControlBase

java.lang.Object
  extended by org.kuali.rice.krad.datadictionary.DictionaryBeanBase
      extended by org.kuali.rice.krad.datadictionary.uif.UifDictionaryBeanBase
          extended by org.kuali.rice.krad.uif.component.ComponentBase
              extended by org.kuali.rice.krad.uif.element.ContentElementBase
                  extended by org.kuali.rice.krad.uif.control.ControlBase
                      extended by org.kuali.rice.krad.uif.control.MultiValueControlBase
All Implemented Interfaces:
Serializable, DictionaryBean, UifDictionaryBean, Component, ScriptEventSupport, Control, MultiValueControl, ContentElement, org.springframework.core.Ordered
Direct Known Subclasses:
CheckboxGroupControl, RadioGroupControl, SelectControl

public abstract class MultiValueControlBase
extends ControlBase
implements MultiValueControl

Base class for controls that accept/display multiple values

Author:
Kuali Rice Team (rice.collab@kuali.org)
See Also:
Serialized Form

Field Summary
 
Fields inherited from interface org.kuali.rice.krad.uif.component.Ordered
INITIAL_ORDER_VALUE
 
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
 
Constructor Summary
MultiValueControlBase()
           
 
Method Summary
 List<Component> getComponentsForLifecycle()
          List of components that are contained within the component and should be sent through the lifecycle
 List<Component> getInlineComponents()
          Gets the inlineComponents which represent components that can be referenced in an option's value by index
 List<KeyValue> getOptions()
          List of values the control can accept.
 List<KeyMessage> getRichOptions()
          Gets the richOptions which contain Message objects with the translated rich message structures, which then can be used by templates to output the appropriate content.
 void performApplyModel(View view, Object model, Component parent)
          Process rich message content that may be in the options, by creating and initializing the richOptions
 void performFinalize(View view, Object model, Component parent)
          Adds appropriate parent data to inputs internal to the controls that may be in rich content of options
 void setInlineComponents(List<Component> inlineComponents)
          Sets the inlineComponents which represent components that can be referenced in an option's value by index
 void setOptions(List<KeyValue> options)
          Sets the List of KeyValue pairs that make up the options for the control
 void setRichOptions(List<KeyMessage> richOptions)
          Sets the richOptions.
 
Methods inherited from class org.kuali.rice.krad.uif.control.ControlBase
completeValidation, getComplexDataAttributesJs, getComponentTypeName, getDisabledConditionControlNames, getDisabledConditionJs, getDisabledReason, getDisabledWhenChangedPropertyNames, getEnabledWhenChangedPropertyNames, getTabIndex, isDisabled, isEvaluateDisabledOnKeyUp, setDisabled, setDisabledReason, setDisabledWhenChangedPropertyNames, setEnabledWhenChangedPropertyNames, setEvaluateDisabledOnKeyUp, setTabIndex
 
Methods inherited from class org.kuali.rice.krad.uif.component.ComponentBase
addDataAttribute, addDataAttributeIfNonEmpty, addStyleClass, appendToStyle, getAdditionalComponentsToRefresh, getAdditionalComponentsToRefreshJs, getAlign, getAllDataAttributesJs, getBaseId, getColSpan, getComponentModifiers, getComponentPrototypes, getComponentSecurity, getComponentSecurityClass, getConditionalRefresh, getConditionalRefreshConditionJs, getConditionalRefreshControlNames, getContext, getCssClasses, getDataAttributes, getFinalizeMethodAdditionalArguments, getFinalizeMethodInvoker, getFinalizeMethodToCall, getId, getMethodToCallOnRefresh, getOnBlurScript, getOnChangeScript, getOnClickScript, getOnCloseScript, getOnDblClickScript, getOnDocumentReadyScript, getOnFocusScript, getOnKeyDownScript, getOnKeyPressScript, getOnKeyUpScript, getOnLoadScript, getOnMouseDownScript, getOnMouseMoveScript, getOnMouseOutScript, getOnMouseOverScript, getOnMouseUpScript, getOnSubmitScript, getOnUnloadScript, getOrder, getProgressiveDisclosureConditionJs, getProgressiveDisclosureControlNames, getProgressiveRender, getPropertyReplacerComponents, getPropertyReplacers, getRefreshTimer, getRefreshWhenChangedPropertyNames, getRenderedHtmlOutput, getRequired, getRowSpan, getSimpleDataAttributes, getStyle, getStyleClassesAsString, getTemplate, getTemplateName, getTemplateOptions, getTemplateOptionsJSString, getTitle, getToolTip, getValign, getWidth, isDisableSessionPersistence, isForceSessionPersistence, isHidden, isProgressiveRenderAndRefresh, isProgressiveRenderViaAJAX, isReadOnly, isRefreshedByAction, isRender, isResetDataOnRefresh, isSelfRendered, isSkipInTabOrder, performInitialization, pushAllToContext, pushObjectToContext, pushToPropertyReplacerContext, setAdditionalComponentsToRefresh, setAlign, setBaseId, setColSpan, setComponentModifiers, setComponentSecurity, setConditionalRefresh, setContext, setCssClasses, setDataAttributes, setDisableSessionPersistence, setFinalizeMethodAdditionalArguments, setFinalizeMethodInvoker, setFinalizeMethodToCall, setForceSessionPersistence, setHidden, setId, setMethodToCallOnRefresh, setOnBlurScript, setOnChangeScript, setOnClickScript, setOnCloseScript, setOnDblClickScript, setOnDocumentReadyScript, setOnFocusScript, setOnKeyDownScript, setOnKeyPressScript, setOnKeyUpScript, setOnLoadScript, setOnMouseDownScript, setOnMouseMoveScript, setOnMouseOutScript, setOnMouseOverScript, setOnMouseUpScript, setOnSubmitScript, setOnUnloadScript, setOrder, setProgressiveRender, setProgressiveRenderAndRefresh, setProgressiveRenderViaAJAX, setPropertyReplacers, setReadOnly, setRefreshedByAction, setRefreshTimer, setRefreshWhenChangedPropertyNames, setRender, setRenderedHtmlOutput, setRequired, setResetDataOnRefresh, setRowSpan, setSelfRendered, setSkipInTabOrder, setStyle, setTemplate, setTemplateName, setTemplateOptions, setTemplateOptionsJSString, setTitle, setToolTip, setValign, setWidth
 
Methods inherited from class org.kuali.rice.krad.datadictionary.uif.UifDictionaryBeanBase
getExpressionGraph, getPropertyExpression, getPropertyExpressions, getRefreshExpressionGraph, setExpressionGraph, setPropertyExpressions, setRefreshExpressionGraph
 
Methods inherited from class org.kuali.rice.krad.datadictionary.DictionaryBeanBase
getComponentCode, getNamespaceCode, setComponentCode, setNamespaceCode
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.kuali.rice.krad.uif.component.Component
addDataAttribute, addStyleClass, appendToStyle, getAdditionalComponentsToRefresh, getAdditionalComponentsToRefreshJs, getAllDataAttributesJs, getBaseId, getColSpan, getComponentModifiers, getComponentPrototypes, getComponentSecurity, getConditionalRefresh, getConditionalRefreshConditionJs, getConditionalRefreshControlNames, getContext, getCssClasses, getDataAttributes, getFinalizeMethodAdditionalArguments, getFinalizeMethodInvoker, getFinalizeMethodToCall, getId, getOrder, getProgressiveDisclosureConditionJs, getProgressiveDisclosureControlNames, getProgressiveRender, getPropertyReplacerComponents, getPropertyReplacers, getRefreshTimer, getRefreshWhenChangedPropertyNames, getRenderedHtmlOutput, getRequired, getRowSpan, getSimpleDataAttributes, getStyle, getTemplate, getTemplateOptions, getTemplateOptionsJSString, getTitle, getToolTip, isDisableSessionPersistence, isForceSessionPersistence, isHidden, isProgressiveRenderAndRefresh, isProgressiveRenderViaAJAX, isReadOnly, isRefreshedByAction, isRender, isResetDataOnRefresh, isSelfRendered, performInitialization, pushAllToContext, pushObjectToContext, setAdditionalComponentsToRefresh, setBaseId, setColSpan, setComponentModifiers, setComponentSecurity, setConditionalRefresh, setContext, setCssClasses, setDataAttributes, setDisableSessionPersistence, setForceSessionPersistence, setHidden, setId, setOrder, setProgressiveRender, setProgressiveRenderAndRefresh, setProgressiveRenderViaAJAX, setPropertyReplacers, setReadOnly, setRefreshedByAction, setRefreshTimer, setRefreshWhenChangedPropertyNames, setRender, setRenderedHtmlOutput, setRequired, setResetDataOnRefresh, setRowSpan, setSelfRendered, setStyle, setTemplate, setTemplateOptions, setTemplateOptionsJSString, setTitle, setToolTip
 
Methods inherited from interface org.kuali.rice.krad.datadictionary.uif.UifDictionaryBean
getExpressionGraph, getPropertyExpression, getPropertyExpressions, getRefreshExpressionGraph, setExpressionGraph, setPropertyExpressions, setRefreshExpressionGraph
 
Methods inherited from interface org.kuali.rice.krad.datadictionary.DictionaryBean
getComponentCode, getNamespaceCode
 
Methods inherited from interface org.kuali.rice.krad.uif.component.ScriptEventSupport
getOnBlurScript, getOnChangeScript, getOnClickScript, getOnCloseScript, getOnDblClickScript, getOnDocumentReadyScript, getOnFocusScript, getOnKeyDownScript, getOnKeyPressScript, getOnKeyUpScript, getOnLoadScript, getOnMouseDownScript, getOnMouseMoveScript, getOnMouseOutScript, getOnMouseOverScript, getOnMouseUpScript, getOnSubmitScript, getOnUnloadScript, setOnBlurScript, setOnLoadScript
 

Constructor Detail

MultiValueControlBase

public MultiValueControlBase()
Method Detail

performApplyModel

public void performApplyModel(View view,
                              Object model,
                              Component parent)
Process rich message content that may be in the options, by creating and initializing the richOptions

Specified by:
performApplyModel in interface Component
Overrides:
performApplyModel in class ControlBase
Parameters:
view - - view instance to which the component belongs
model - - Top level object containing the data (could be the form or a
See Also:
ComponentBase.performApplyModel(org.kuali.rice.krad.uif.view.View, java.lang.Object, org.kuali.rice.krad.uif.component.Component)

performFinalize

public void performFinalize(View view,
                            Object model,
                            Component parent)
Adds appropriate parent data to inputs internal to the controls that may be in rich content of options

Specified by:
performFinalize in interface Component
Overrides:
performFinalize in class ControlBase
Parameters:
view - - view instance that should be finalized for rendering
model - - top level object containing the data
parent - - parent component
See Also:
Component.performFinalize(org.kuali.rice.krad.uif.view.View, Object, org.kuali.rice.krad.uif.component.Component)

getComponentsForLifecycle

public List<Component> getComponentsForLifecycle()
Description copied from interface: Component
List of components that are contained within the component and should be sent through the lifecycle

Used by ViewHelperService for the various lifecycle callbacks

Specified by:
getComponentsForLifecycle in interface Component
Overrides:
getComponentsForLifecycle in class ComponentBase
Returns:
List child components
See Also:
ComponentBase.getComponentsForLifecycle()

getOptions

public List<KeyValue> getOptions()
Description copied from interface: MultiValueControl
List of values the control can accept. Each value consists of a key and a label. The key is the what will be submitted back if the user selects the choice, the label is what will be displayed to the user for the choice.

KeyLabelPair instances are usually generated by the KeyValueFinder associated with the Field for which the control belongs

Specified by:
getOptions in interface MultiValueControl
Returns:
List of KeyLabelPair instances
See Also:
MultiValueControl.getOptions()

setOptions

public void setOptions(List<KeyValue> options)
Description copied from interface: MultiValueControl
Sets the List of KeyValue pairs that make up the options for the control

Specified by:
setOptions in interface MultiValueControl
See Also:
org.kuali.rice.krad.uif.control.MultiValueControl#setOptions(java.util.List)

getInlineComponents

public List<Component> getInlineComponents()
Gets the inlineComponents which represent components that can be referenced in an option's value by index

Returns:
the components that can be used in rich values of options

setInlineComponents

public void setInlineComponents(List<Component> inlineComponents)
Sets the inlineComponents which represent components that can be referenced in an option's value by index

Parameters:
inlineComponents -

getRichOptions

public List<KeyMessage> getRichOptions()
Gets the richOptions which contain Message objects with the translated rich message structures, which then can be used by templates to output the appropriate content.

Returns:
richOptions which include a message object with the translated value content

setRichOptions

public void setRichOptions(List<KeyMessage> richOptions)
Sets the richOptions. This will always override/ignore options if set.

Messages MUST be defined when using this setter, do not use this setter for most cases as setting options through setOptions, with a richMessage value, is appropriate in MOST cases. This setter is only available for full control.

Parameters:
richOptions - with their messages predefined


Copyright © 2005-2012 The Kuali Foundation. All Rights Reserved.