Oracle Fusion Middleware Java API Reference for Oracle ADF Model
11g Release 1 (11.1.1.7.0)

E10653-08

oracle.jbo.uicli.jui
Class JUSpinnerBinding

java.lang.Object
  extended by java.util.AbstractMap
      extended by oracle.jbo.common.JboAbstractMap
          extended by oracle.adf.model.binding.DCControlBinding
              extended by oracle.jbo.uicli.binding.JUControlBinding
                  extended by oracle.jbo.uicli.binding.JUCtrlValueBinding
                      extended by oracle.jbo.uicli.binding.JUCtrlAttrsBinding
                          extended by oracle.jbo.uicli.binding.JUCtrlListBinding
                              extended by oracle.jbo.uicli.jui.JUSpinnerBinding
All Implemented Interfaces:
java.util.EventListener, java.util.Map, AttributeBinding, ControlBinding, RowNavigationListener, RowSetListener, RowSetManagementListener, StructureDef, JUCtrlInputValueHandler, JUCtrlValueHandler

public class JUSpinnerBinding
extends JUCtrlListBinding

Implements binding for JSpinner control. JSpinner can be bound in the following ways:


Nested Class Summary
static class JUSpinnerBinding.JUSpinnerEditor
           
 
Nested classes/interfaces inherited from class java.util.AbstractMap
java.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>
 
Nested classes/interfaces inherited from interface java.util.Map
java.util.Map.Entry<K,V>
 
Field Summary
protected  javax.swing.JComponent mEditor
           
protected  javax.swing.SpinnerModel modelImpl
           
protected  boolean mValueUpdating
           
protected  boolean settingUpList
           
 
Fields inherited from class oracle.jbo.uicli.binding.JUCtrlListBinding
DH_CONTROL_TYPE, DH_DISPLAY_HEIGHT, DH_DISPLAY_HINT, DH_DISPLAY_WIDTH, DH_FORMAT, DH_LABEL, DH_TOOLTIP, LIST_ADD_NULL_AT_END, LIST_ADD_NULL_AT_START, LIST_ADD_NULL_NOWHERE, LIST_ADD_NULL_UNINIT, LIST_OPER_MULTI_SELECT, LIST_OPER_NAVIGATE, LIST_OPER_SET_ATTRIBUTE, LIST_OPER_SET_DELIMITED_ATTRIBUTE, LISTITEM_DisplayValues, LISTITEM_Index, LISTITEM_Prompt, LISTITEM_Selected, LISTITEM_SelectedIndex, LISTITEM_SelectedIndices, LOV_SRC_ATTRNAMES, LOV_SRC_EL_EXPR, LOV_SRC_ROW, LOV_SRC_ROW_DATA, mFirstDisplayAttr, mListAttrNames, mListDisplayAttrNames, mListIterBinding, mNullValueFlag, mSingleAttrList, mStaticList, mValueList, ROW
 
Fields inherited from class oracle.jbo.uicli.binding.JUCtrlValueBinding
ATTR_ATTRIBUTE, ATTR_ATTRIBUTE_DEF, ATTR_ATTRIBUTE_DEFS, ATTR_ATTRIBUTE_VALUE, ATTR_ATTRIBUTE_VALUES, ATTR_ATTRIBUTES, ATTR_AUTOSUBMIT, ATTR_DISPLAY_HEIGHT, ATTR_DISPLAY_HINT, ATTR_DISPLAY_WIDTH, ATTR_FORMAT, ATTR_FORMATS, ATTR_HINTS, ATTR_INPUT_VALUE, ATTR_LABEL, ATTR_LABELS, ATTR_LABELSET, ATTR_MANDATORY, ATTR_PATH, ATTR_TOOLTIP, ATTR_UPDATEABLE, ATTR_VIEWABLE, DATACHANGE_EVENT_POLICY, GET_ALLOWS, mAttrs, mHasInputVal, mInputVal, SEP_LIST_DISPLAY
 
Fields inherited from class oracle.adf.model.binding.DCControlBinding
ATTR_CURRENTROW, ATTR_DEF, ATTR_ERROR, ATTR_ERRORS, ATTR_FULLNAME, ATTR_ITER, ATTR_NAME, DC_BINDING_ERROR, mAttributeListener, mInternalGet_KeyResolved, mPermission, mPermissionInfo, ROW_KEY_STR
 
Fields inherited from class oracle.jbo.common.JboAbstractMap
MAP_NULL_VALUE
 
Constructor Summary
JUSpinnerBinding(javax.swing.JSpinner control, JUIteratorBinding iterBinding, java.lang.String[] attrNames, int listOperMode)
          JUSpinnerBinding to be used in Navigation mode.
JUSpinnerBinding(javax.swing.JSpinner control, JUIteratorBinding iterBinding, java.lang.String[] attrNames, JUIteratorBinding listRSI, java.lang.String[] listAttrNames, java.lang.String[] listDisplayedAttrNames)
          Binds separate ViewObject/RowSets for display and updates to the same listbox.
JUSpinnerBinding(javax.swing.JSpinner control, JUIteratorBinding iterBinding, java.lang.String[] attrNames, java.lang.Object[] valueList)
           
JUSpinnerBinding(javax.swing.JSpinner control, JUIteratorBinding iterBinding, java.lang.String[] attrNames, javax.swing.SpinnerDateModel sdm)
           
JUSpinnerBinding(javax.swing.JSpinner control, JUIteratorBinding iterBinding, java.lang.String[] attrNames, javax.swing.SpinnerDateModel sdm, java.lang.String formatString)
           
JUSpinnerBinding(javax.swing.JSpinner control, JUIteratorBinding iterBinding, java.lang.String[] attrNames, javax.swing.SpinnerListModel slm)
           
JUSpinnerBinding(javax.swing.JSpinner control, JUIteratorBinding iterBinding, java.lang.String[] attrNames, javax.swing.SpinnerNumberModel snm)
           
JUSpinnerBinding(javax.swing.JSpinner control, JUIteratorBinding iterBinding, java.lang.String[] attrNames, javax.swing.SpinnerNumberModel snm, java.lang.String formatString)
           
 
Method Summary
 void addControlToPanel(java.lang.Object panel, java.lang.Object layoutObject, java.lang.Object layoutCons)
          *** For internal framework use only ***
static javax.swing.SpinnerModel createEnumerationBinding(JUFormBinding formBinding, javax.swing.JSpinner control, java.lang.String voInstanceName, java.lang.String voIterName, java.lang.String voIterBindingName, java.lang.String attrName, java.lang.Object[] values)
          Use this method to bind a JSpinner control to a ViewObject/RowSet, identified by voInstanceName.
static javax.swing.SpinnerModel createEnumerationBinding(JUFormBinding formBinding, javax.swing.JSpinner control, java.lang.String voInstanceName, java.lang.String voIterName, java.lang.String voIterBindingName, java.lang.String attrName, javax.swing.SpinnerDateModel sdm)
          Use this method to bind a JSpinner control to a ViewObject/RowSet, identified by voInstanceName.
static javax.swing.SpinnerModel createEnumerationBinding(JUFormBinding formBinding, javax.swing.JSpinner control, java.lang.String voInstanceName, java.lang.String voIterName, java.lang.String voIterBindingName, java.lang.String attrName, javax.swing.SpinnerListModel slm)
          Use this method to bind a JSpinner control to a ViewObject/RowSet, identified by voInstanceName.
static javax.swing.SpinnerModel createEnumerationBinding(JUFormBinding formBinding, javax.swing.JSpinner control, java.lang.String voInstanceName, java.lang.String voIterName, java.lang.String voIterBindingName, java.lang.String attrName, javax.swing.SpinnerNumberModel snm)
          Use this method to bind a JSpinner control to a ViewObject/RowSet, identified by voInstanceName.
static javax.swing.SpinnerModel createLovBinding(JUFormBinding formBinding, javax.swing.JSpinner control, java.lang.String voInstanceName, java.lang.String voIterName, java.lang.String voIterBindingName, java.lang.String[] attrNames, java.lang.String listVOInstanceName)
          Use this binding when the JSpinner control is used in LOV mode to update another attribute in a BC4J View Object.
static javax.swing.SpinnerModel createLovBinding(JUFormBinding formBinding, javax.swing.JSpinner control, java.lang.String voInstanceName, java.lang.String voIterName, java.lang.String voIterBindingName, java.lang.String[] voAttrNames, java.lang.String lovVOInstanceName, java.lang.String[] lovVOAttrNames, java.lang.String[] lovVODisplayedAttrNames)
          Use this binding when two ViewObjects are to be used in this Spinner control: one for displaying of values and the other ViewObject whose rows are updated.
static javax.swing.SpinnerModel createNavigationBinding(JUFormBinding formBinding, javax.swing.JSpinner control, java.lang.String voInstanceName, java.lang.String voIterName, java.lang.String voIterBindingName, java.lang.String[] voAttrNames)
          Use this binding when the JSpinner control is used as a navigation control to iterate through a range of rows in a RowSet.
 java.lang.Object findMatchingListValue(java.lang.Object value)
           
 java.lang.Object getControlModel(java.lang.Object control)
          Gets the associated View's model object.
protected  java.lang.String getDefaultDateFormatString()
           
protected  java.lang.String getDefaultNumericFormatString()
           
protected  javax.swing.SpinnerModel getModelImpl()
           
 java.lang.Object getValueAt(int attrIndex)
          Gets the value from the control for the attribute at the given index.
protected  boolean isViewInitialized()
           
 void navigated(NavigationEvent event)
          *** For internal framework use only ***
protected  void navigateTo(javax.swing.event.ChangeEvent e)
           
protected  void navigateTo(int rangeIndex)
           
 void refreshControl()
          *** For internal framework use only ***
 void setControl(java.lang.Object control)
          Sets the associated Swing control.
 void setDataValueAt(java.lang.Object value, int attrIndex)
           
protected  void setupListItems(boolean clean, boolean keepSelectedIndex)
          If this list is displaying a single attribute and updates a single attribute, then this method fetches the attribute value from all the rows in the given LOV list iterator and sets that as the list of values to display in the bound control.
 void setValueAt(java.lang.Object value, int attrIndex)
          Updates the control/control-binding with the latest value of the attribute at the given index with the given value.
protected  void updateAttributeValue(java.lang.Object value)
           
protected  void updateTargetFromSelectedValue(java.lang.Object val)
           
 
Methods inherited from class oracle.jbo.uicli.binding.JUCtrlListBinding
addBindingChangeListener, addNullAndSetValueList, addRowToMRU, addSelectionToMRU, bindRowSetIterator, clearMRU, clearSelectedIndices, convertValueList, createListIterBinding, createRowSetIterator, filterList, findAndUpdateSelectedIndex, findListIndex, findListIndex, findOrCreateLOVDialogIteratorBinding, findShuttleAvailableRows, findShuttleSelectedRows, findValue, getAttributeDefs, getComboDisplayAttributeCount, getDelimiter, getDerivedAttrNames, getDisplayAttributeDefs, getDisplayCriteriaName, getDisplayData, getDisplayHints, getDisplayListIterator, getDisplayWidth, getFilteredRowSetIterator, getFilteredRowSetIteratorWithCaseCheck, getFirstDisplayAttrDef, getInputValueInRow, getInputValueOnError, getIterBindingDefOptions, getListAttrNames, getListBindingName, getListDisplayAttrNames, getListIterBinding, getListOperMode, getListRowSetIterator, getLovSourceOption, getMRUSize, getMRUString, getNullValueFlag, getNullValueIndex, getPreferredListIterBinding, getPreferredListMode, getPreferredListRowSetIterator, getSelectedIndex, getSelectedIndexValue, getSelectedIndices, getSelectedValue, getSelectedValues, getSelectionAttributeName, getSelectionIndices, getServerBindingName, getTargetRowData, getValueFromList, getValueList, handleFilteredList, hasMRU, hasNullValue, initFromServerBinding, initResources, internalGet, internalGetDisplayWidth, internalPut, isAutoSubmit, isControlQueriable, isMandatory, isSingleAttrList, isUpdateable, iteratorClosed, iteratorReset, matchTargetWithLov, moveDown, moveToBottom, moveToTop, moveUp, processNewInputValue, put, rangeRefreshed, rangeScrolled, refreshFromServerListBinding, release, releaseLOVDialogIteratorBinding, removeBindingChangeListener, resetAttributeDefs, resetShuttle, rowDeleted, rowInserted, rowUpdated, setAllowBlindMatchInFilter, setAttributeFromValueList, setDef, setFetchDataOnSetup, setInputValueInRow, setListIterBinding, setListOperMode, setListValueAsSelected, setNullValueProperties, setPreferredListMode, setSelectedIndex, setSelectedIndexValue, setSelectedIndices, setSelectionIndices, setServerBindingName, setStaticList, setTargetAttrsFromLovRow, setTargetAttrsFromLovRowAndUpdateMRU, setValueList, shuttle, toString, updateNavigated, updateValuesFromRow, usesServerBinding
 
Methods inherited from class oracle.jbo.uicli.binding.JUCtrlAttrsBinding
createAttributeBinding, setControlEnabled, updateValuesFromRows
 
Methods inherited from class oracle.jbo.uicli.binding.JUCtrlValueBinding
addBindingContainerChangeListenerForCtxEvent, addDataChangeListener, clearAttrDefs, clearEventsCache, compareAndSetAttribute, createAndNotifyDCE, createEventProducer, displayInShortForm, ensureVariableManager, eventForMyRow, fetchAttrDefs, findAttributeDef, generateDCE, getAttribute, getAttribute, getAttribute, getAttributeCount, getAttributeDef, getAttributeDef, getAttributeDefsForRow, getAttributeFromRow, getAttributeFromRow, getAttributeFromRow, getAttributeFromRow, getAttributeFromRow, getAttributeIndexOf, getAttributeNames, getAttributes, getAttributes, getAttributeUIHelper, getAttributeValidators, getAttributeValidators, getAttributeValue, getAttributeValue, getAttributeValueFromRow, getAttributeValues, getAttributeValues, getAttrViewExpressions, getBindingHint, getCachedEvents, getChangeEventPolicy, getColumnNameForQuery, getControlType, getDataChangeEventPolicy, getDataChangeListener, getDisplayHeight, getDisplayHint, getError, getErrors, getEventProducer, getFormat, getFormats, getFormattedAttributeValue, getHint, getHint, getHints, getInputErrorsForRowKey, getInputValue, getInputValue, getInputValueHandler, getIteratorBindingForDCE, getIteratorRenderHint, getLabel, getLabel, getLabels, getLabelSet, getLastEventId, getLocaleContext, getMasterKeyPathForDCE, getMergedAttributeValues, getNullValueString, getPath, getPermissionDef, getPermissionHolder, getPermissionInfo, getSelectionDef, getState, getTooltip, getTooltip, hasEventProducer, hasFormatInformation, hasServerBindingChanged, hasVariables, internalGetRow, internalHasPermission, internalHasPermission, isArrayIteratorType, isAttributeMandatory, isAttributeUpdateable, isAttributeUpdateable, isAttributeUpdateable, isAttributeUpdateable, isEventsCachingEnabled, isNewInputValue, isNullInsertKeyPathForDCE, isPushDataChangeEvents, isPushOrPollDataChangeEvents, isViewable, lookupAttributeDef, notifyDataChangeEvent, notifyDataExceptionEvent, notifyDCE, pinDataControl, processInputException, removeAttrName, removeDataChangeListener, removeFromDCExceptions, resetInputState, resolvePath, restoreFromState, setArrayIteratorType, setAttribute, setAttribute, setAttributeInRow, setAttributeInRow, setAttributeInRow, setAttributeInRow, setAttributeInRow, setAttributeInRow, setAttributeNames, setAttributes, setAttributeValue, setAttributeValuesInRow, setAttrViewExpressions, setError, setEventProducer, setEventsCaching, setInputValue, setInputValue, setInputValueHandler, setIteratorBinding, setListener, setNullValueString, startEvents, stopEditing, stopEvents, updateRangeScrolled, updateRow, updateRowDeleted, updateRowInserted, useRowSpecificHints, validateInputValue
 
Methods inherited from class oracle.jbo.uicli.binding.JUControlBinding
getCurrentRow, getFormBinding, getIteratorBinding, reportException, setFormBinding
 
Methods inherited from class oracle.adf.model.binding.DCControlBinding
addToDCExceptions, evaluateBooleanExpression, executeQuery, executeQueryIfNeeded, get, getAllRowsInRange, getApplicationModule, getAttributeListener, getBindingContainer, getControl, getDCIteratorBinding, getDef, getDefFullName, getDefName, getFullName, getLayoutObject, getName, getPermission, getPermissionTargetName, getRowAtRangeIndex, getRowIterator, getTransaction, getViewableExpr, getViewObject, hashCode, internalSetName, isControlViewable, isReleased, needsEstimatedRowCount, release, reportException, resetAttributeExceptionInRow, setBindingContainer, setDataControlPinned, setListener, setName, setViewableExpr
 
Methods inherited from class oracle.jbo.common.JboAbstractMap
entrySet, equals, setThrowIfPropertyNotFoundOnGet
 
Methods inherited from class java.util.AbstractMap
clear, clone, containsKey, containsValue, isEmpty, keySet, putAll, remove, size, values
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface oracle.adf.model.AttributeBinding
getErrors, getInputValue, getLabel, setInputValue, validateInputValue
 
Methods inherited from interface oracle.adf.model.ControlBinding
setListener
 
Methods inherited from interface oracle.binding.ControlBinding
getName, getPath, release, resolvePath, setListener
 
Methods inherited from interface oracle.jbo.StructureDef
getDefFullName, getDefName, getFullName, getName
 

Field Detail

modelImpl

protected javax.swing.SpinnerModel modelImpl

mValueUpdating

protected boolean mValueUpdating

settingUpList

protected boolean settingUpList

mEditor

protected javax.swing.JComponent mEditor
Constructor Detail

JUSpinnerBinding

public JUSpinnerBinding(javax.swing.JSpinner control,
                        JUIteratorBinding iterBinding,
                        java.lang.String[] attrNames,
                        int listOperMode)
JUSpinnerBinding to be used in Navigation mode.

Parameters:
control - The control instance which should be bound to a ViewObject's attribute.
iterBinding - iterator binding to use
attrNames - The names of the attributes of this ViewObject to display

JUSpinnerBinding

public JUSpinnerBinding(javax.swing.JSpinner control,
                        JUIteratorBinding iterBinding,
                        java.lang.String[] attrNames,
                        java.lang.Object[] valueList)

JUSpinnerBinding

public JUSpinnerBinding(javax.swing.JSpinner control,
                        JUIteratorBinding iterBinding,
                        java.lang.String[] attrNames,
                        javax.swing.SpinnerListModel slm)

JUSpinnerBinding

public JUSpinnerBinding(javax.swing.JSpinner control,
                        JUIteratorBinding iterBinding,
                        java.lang.String[] attrNames,
                        javax.swing.SpinnerDateModel sdm)

JUSpinnerBinding

public JUSpinnerBinding(javax.swing.JSpinner control,
                        JUIteratorBinding iterBinding,
                        java.lang.String[] attrNames,
                        javax.swing.SpinnerDateModel sdm,
                        java.lang.String formatString)

JUSpinnerBinding

public JUSpinnerBinding(javax.swing.JSpinner control,
                        JUIteratorBinding iterBinding,
                        java.lang.String[] attrNames,
                        javax.swing.SpinnerNumberModel snm)

JUSpinnerBinding

public JUSpinnerBinding(javax.swing.JSpinner control,
                        JUIteratorBinding iterBinding,
                        java.lang.String[] attrNames,
                        javax.swing.SpinnerNumberModel snm,
                        java.lang.String formatString)

JUSpinnerBinding

public JUSpinnerBinding(javax.swing.JSpinner control,
                        JUIteratorBinding iterBinding,
                        java.lang.String[] attrNames,
                        JUIteratorBinding listRSI,
                        java.lang.String[] listAttrNames,
                        java.lang.String[] listDisplayedAttrNames)
Binds separate ViewObject/RowSets for display and updates to the same listbox. Use this binding constructor to provide a separate iterator binding for update and a separate iterator binding which provides rows for display in the listbox. Optionally, the attributes displayed can be different from the attributes that should be used to update a corresponding set of attributes in the target/updateable ViewObject.

Parameters:
control - JSpinner control instance to associate this binding with.
iterBinding - Provides the RowSet in which the current row is updated based on selection in the listbox.
attrNames - An ordered array of attribute names to update in a ViewObject. This list should have the same number of attributes as in listAttrNames which provides the corresponding attribute names from the display ViewObject/RowSet.
listRSI - Provides the RowSet that is used to display data in the listbox.
listAttrNames - An ordered list of attribute names which are used to get the values to update into the attributes from the attrNames list in the target ViewObject. If this list is null, the attribute names for display are set to the same as attrNames.
listDisplayedAttrNames - An ordered list of attribute names that specify the attributes to display from rows in the display ViewObject/RowSet. If this list is null, attribute names are assumed to be same as in attrNames.
Method Detail

getControlModel

public java.lang.Object getControlModel(java.lang.Object control)
Gets the associated View's model object.

Overrides:
getControlModel in class DCControlBinding

createNavigationBinding

public static javax.swing.SpinnerModel createNavigationBinding(JUFormBinding formBinding,
                                                               javax.swing.JSpinner control,
                                                               java.lang.String voInstanceName,
                                                               java.lang.String voIterName,
                                                               java.lang.String voIterBindingName,
                                                               java.lang.String[] voAttrNames)
Use this binding when the JSpinner control is used as a navigation control to iterate through a range of rows in a RowSet.

Parameters:
formBinding - The containing JUPanelBinding in which the given iterator binding would be found/created.
control - The control instance which should be bound to a ViewObject's attribute.
voInstanceName - Name of the instance of the ViewObject in a BC4J ApplicationModule.
voIterName - Runtime instance name of the iterator in the ViewObject (optional).
voIterBindingName - Instance name of the iterator binding that uniquely identifies an iterator binding object used to read data in this given JUPanelBinding instance.
voAttrNames - The names of the attributes of this ViewObject rows that contain data to display/edit in the associated text control.
Returns:
JUSpinnerBinding An instance of control binding that works with the given JSpinner.

createLovBinding

public static javax.swing.SpinnerModel createLovBinding(JUFormBinding formBinding,
                                                        javax.swing.JSpinner control,
                                                        java.lang.String voInstanceName,
                                                        java.lang.String voIterName,
                                                        java.lang.String voIterBindingName,
                                                        java.lang.String[] attrNames,
                                                        java.lang.String listVOInstanceName)
Use this binding when the JSpinner control is used in LOV mode to update another attribute in a BC4J View Object.

Parameters:
formBinding - The containing JUPanelBinding in which the given iterator binding would be found/created.
control - The control instance which should be bound to a ViewObject's attribute.
voInstanceName - Name of the instance of the ViewObject in a BC4J ApplicationModule.
voIterName - Runtime instance name of the iterator in the ViewObject (optional).
voIterBindingName - Instance name of the iterator binding that uniquely identifies an iterator binding object used to read/write data in this given JUPanelBinding instance.
attrNames - The name of the attribute of this ViewObject rows that contain data to display/edit in the associated control.
listVOInstanceName - list View Object instance name
Returns:
JUSpinnerBinding An instance of control binding that works with the given JSpinner.

createLovBinding

public static javax.swing.SpinnerModel createLovBinding(JUFormBinding formBinding,
                                                        javax.swing.JSpinner control,
                                                        java.lang.String voInstanceName,
                                                        java.lang.String voIterName,
                                                        java.lang.String voIterBindingName,
                                                        java.lang.String[] voAttrNames,
                                                        java.lang.String lovVOInstanceName,
                                                        java.lang.String[] lovVOAttrNames,
                                                        java.lang.String[] lovVODisplayedAttrNames)
Use this binding when two ViewObjects are to be used in this Spinner control: one for displaying of values and the other ViewObject whose rows are updated.


createEnumerationBinding

public static javax.swing.SpinnerModel createEnumerationBinding(JUFormBinding formBinding,
                                                                javax.swing.JSpinner control,
                                                                java.lang.String voInstanceName,
                                                                java.lang.String voIterName,
                                                                java.lang.String voIterBindingName,
                                                                java.lang.String attrName,
                                                                java.lang.Object[] values)
Use this method to bind a JSpinner control to a ViewObject/RowSet, identified by voInstanceName. The values for the spinner is specified as a static list of values. The control is used to display/update a particular attribute in a ViewObject.

Parameters:
formBinding - The containing JUPanelBinding in which the given iterator binding would be found/created.
control - The control instance which should be bound to a ViewObject's attribute.
voInstanceName - Name of the instance of the ViewObject in a BC4J ApplicationModule.
voIterName - Runtime instance name of the iterator in the ViewObject (optional).
voIterBindingName - Instance name of the iterator binding that uniquely identifies an iterator binding object used to read data in this given JUPanelBinding instance.
attrName - The name of the attribute of this ViewObject to update
values - static list of values for the spinner
Returns:
Object that can be used as model for JSpinner and can display/update attribute in BC4J ViewOject.

createEnumerationBinding

public static javax.swing.SpinnerModel createEnumerationBinding(JUFormBinding formBinding,
                                                                javax.swing.JSpinner control,
                                                                java.lang.String voInstanceName,
                                                                java.lang.String voIterName,
                                                                java.lang.String voIterBindingName,
                                                                java.lang.String attrName,
                                                                javax.swing.SpinnerListModel slm)
Use this method to bind a JSpinner control to a ViewObject/RowSet, identified by voInstanceName. The model object returned extends SpinnerListModel. The list of values for the JSpinner is specified through an instance of SpinnerListModel.

Parameters:
formBinding - The containing JUPanelBinding in which the given iterator binding would be found/created.
control - The control instance which should be bound to a ViewObject's attribute.
voInstanceName - Name of the instance of the ViewObject in a BC4J ApplicationModule.
voIterName - Runtime instance name of the iterator in the ViewObject (optional).
voIterBindingName - Instance name of the iterator binding that uniquely identifies an iterator binding object used to read data in this given JUPanelBinding instance.
attrName - The name of the attribute of this ViewObject to update
slm - instance of SpinnerNumberModel which provides the range of value for the spinner as well as the step size.
Returns:
Object that can be used as model for JSpinner and can display/update attribute in BC4J ViewOject.

createEnumerationBinding

public static javax.swing.SpinnerModel createEnumerationBinding(JUFormBinding formBinding,
                                                                javax.swing.JSpinner control,
                                                                java.lang.String voInstanceName,
                                                                java.lang.String voIterName,
                                                                java.lang.String voIterBindingName,
                                                                java.lang.String attrName,
                                                                javax.swing.SpinnerDateModel sdm)
Use this method to bind a JSpinner control to a ViewObject/RowSet, identified by voInstanceName. The model object returned extends SpinnerDateModel. This method also sets an instance of JSpinner.DateEditor as the editor for the control. The format string UI hint defined in the middle tier is used as default format for the editor. The range of values for the JSpinner and the step size is specified through an instance of SpinnerDateModel.

Parameters:
formBinding - The containing JUPanelBinding in which the given iterator binding would be found/created.
control - The control instance which should be bound to a ViewObject's attribute.
voInstanceName - Name of the instance of the ViewObject in a BC4J ApplicationModule.
voIterName - Runtime instance name of the iterator in the ViewObject (optional).
voIterBindingName - Instance name of the iterator binding that uniquely identifies an iterator binding object used to read data in this given JUPanelBinding instance.
attrName - The name of the attribute of this ViewObject to update
sdm - instance of SpinnerDateModel which provides the range of value for the spinner as well as the step size.
Returns:
Object that can be used as model for JSpinner and can display/update attribute in BC4J ViewOject.

createEnumerationBinding

public static javax.swing.SpinnerModel createEnumerationBinding(JUFormBinding formBinding,
                                                                javax.swing.JSpinner control,
                                                                java.lang.String voInstanceName,
                                                                java.lang.String voIterName,
                                                                java.lang.String voIterBindingName,
                                                                java.lang.String attrName,
                                                                javax.swing.SpinnerNumberModel snm)
Use this method to bind a JSpinner control to a ViewObject/RowSet, identified by voInstanceName. The model object returned extends SpinnerNumberModel. This method also sets an instance of JSpinner.NumberEditor as the editor for the control. The format string UI hint defined in the middle tier is used as default format for the editor. The range of values for the JSpinner and the step size is specified through an instance of SpinnerNumberModel.

Parameters:
formBinding - The containing JUPanelBinding in which the given iterator binding would be found/created.
control - The control instance which should be bound to a ViewObject's attribute.
voInstanceName - Name of the instance of the ViewObject in a BC4J ApplicationModule.
voIterName - Runtime instance name of the iterator in the ViewObject (optional).
voIterBindingName - Instance name of the iterator binding that uniquely identifies an iterator binding object used to read data in this given JUPanelBinding instance.
attrName - The name of the attribute of this ViewObject to update
snm - instance of SpinnerNumberModel which provides the range of value for the spinner as well as the step size.
Returns:
Object that can be used as model for JSpinner and can display/update attribute in BC4J ViewOject.

getModelImpl

protected javax.swing.SpinnerModel getModelImpl()

refreshControl

public void refreshControl()
Description copied from class: JUCtrlAttrsBinding
*** For internal framework use only ***

Updates the values in a control that is bound using an Iterator already in use. (a valid row iterator) If you do not call this method, your control won't update unless you refresh the Iterator.

Overrides:
refreshControl in class JUCtrlAttrsBinding

addControlToPanel

public void addControlToPanel(java.lang.Object panel,
                              java.lang.Object layoutObject,
                              java.lang.Object layoutCons)
*** For internal framework use only ***

Overrides:
addControlToPanel in class JUCtrlListBinding

setControl

public void setControl(java.lang.Object control)
Description copied from class: DCControlBinding
Sets the associated Swing control.

Overrides:
setControl in class DCControlBinding

getValueAt

public java.lang.Object getValueAt(int attrIndex)
Gets the value from the control for the attribute at the given index. (The index is calculated from the list of attributes this control binding is bound to as passed in the constructor). Framework uses this method to get the attribute value from the control and pass it on to the Row object on the BC4J side.

Overrides:
getValueAt in class JUCtrlListBinding

setValueAt

public void setValueAt(java.lang.Object value,
                       int attrIndex)
Updates the control/control-binding with the latest value of the attribute at the given index with the given value. This method is used by the framework to update the control with attribute values from a BC4J row.

Overrides:
setValueAt in class JUCtrlListBinding

findMatchingListValue

public java.lang.Object findMatchingListValue(java.lang.Object value)
Overrides:
findMatchingListValue in class JUCtrlListBinding

setDataValueAt

public void setDataValueAt(java.lang.Object value,
                           int attrIndex)
Overrides:
setDataValueAt in class JUCtrlListBinding

navigated

public void navigated(NavigationEvent event)
*** For internal framework use only ***

Specified by:
navigated in interface RowNavigationListener
Specified by:
navigated in interface RowSetListener
Overrides:
navigated in class JUCtrlListBinding
Parameters:
event - a description of the new and previous current rows.

isViewInitialized

protected boolean isViewInitialized()
Overrides:
isViewInitialized in class JUCtrlListBinding

setupListItems

protected void setupListItems(boolean clean,
                              boolean keepSelectedIndex)
Description copied from class: JUCtrlListBinding
If this list is displaying a single attribute and updates a single attribute, then this method fetches the attribute value from all the rows in the given LOV list iterator and sets that as the list of values to display in the bound control.

If this list is displaying multiple attributes and/or is used in navigation mode, then the valueList is set with the list of all rows from the LOV Iterator binding. In this case, this binding also listens to events from the RowSetIterator for row currency changes, new rows, etc.

Overrides:
setupListItems in class JUCtrlListBinding

updateAttributeValue

protected void updateAttributeValue(java.lang.Object value)

updateTargetFromSelectedValue

protected void updateTargetFromSelectedValue(java.lang.Object val)
Overrides:
updateTargetFromSelectedValue in class JUCtrlListBinding

navigateTo

protected void navigateTo(javax.swing.event.ChangeEvent e)

navigateTo

protected void navigateTo(int rangeIndex)

getDefaultDateFormatString

protected java.lang.String getDefaultDateFormatString()

getDefaultNumericFormatString

protected java.lang.String getDefaultNumericFormatString()

Oracle Fusion Middleware Java API Reference for Oracle ADF Model
11g Release 1 (11.1.1.7.0)

E10653-08

Copyright © 1997, 2013, Oracle. All rights reserved.