Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.2.0)

E17493-03


oracle.ide.controls
Class AbstractPicker

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by javax.swing.JComboBox
                  extended by oracle.ide.controls.AbstractPicker

All Implemented Interfaces:
java.awt.event.ActionListener, java.awt.image.ImageObserver, java.awt.ItemSelectable, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible, javax.swing.event.ListDataListener
Direct Known Subclasses:
TablePicker

public abstract class AbstractPicker
extends javax.swing.JComboBox
implements java.awt.event.ActionListener
See Also:
Serialized Form

Nested Class Summary
static interface AbstractPicker.PickerResultValidator
          The interface defining Validators for AbstractPicker browse actions.
static interface AbstractPicker.PickerValueEncoder
          The interface defining Encoders for AbstractPicker values.

 

Nested classes/interfaces inherited from class javax.swing.JComboBox
javax.swing.JComboBox.AccessibleJComboBox, javax.swing.JComboBox.KeySelectionManager

 

Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent

 

Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer

 

Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy

 

Field Summary
protected  AbstractPicker.PickerValueEncoder encoder
           
protected  AbstractPicker.PickerResultValidator validator
           

 

Fields inherited from class javax.swing.JComboBox
actionCommand, dataModel, editor, isEditable, keySelectionManager, lightWeightPopupEnabled, maximumRowCount, renderer, selectedItemReminder

 

Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW

 

Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT

 

Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH

 

Constructor Summary
AbstractPicker()
           

 

Method Summary
 void actionPerformed(java.awt.event.ActionEvent ae)
           
protected  void addValue(java.lang.Object value)
          Adds the value to the model.
protected abstract  void doBrowse()
           
 java.lang.Object getCurrentValue()
           
 AbstractPicker.PickerValueEncoder getEncoder()
          Retrieve the Encoder used by this AbstractPicker.
protected  java.lang.String getInvalidValueErrorHelpID()
          Retrieves the HelpID string to use in the error dialog shown when the entered value is invalid.
protected  java.lang.String getInvalidValueErrorTitle()
          Retrieves the title string to use in the error dialog when the entered value is invalid.
 java.lang.Object getSelectedItem()
           
 AbstractPicker.PickerResultValidator getValidator()
          Retrieve the PickerResultValidator used by this AbstractPicker to validate the results of Browse actions.
 void requestFocus()
           
 void setBrowseResult(java.lang.Object result)
          Set the value resulting from a Browse.
 void setCurrentValue(java.lang.Object newCurrentValue)
           
 void setEncoder(AbstractPicker.PickerValueEncoder newEncoder)
          Set the Encoder used by this AbstractPicker.
 void setSelectedItem(java.lang.Object newValue)
           
 void setValidator(AbstractPicker.PickerResultValidator newValidator)
          Set the Validator used by this AbstractPicker.

 

Methods inherited from class javax.swing.JComboBox
actionPropertyChanged, addActionListener, addItem, addItemListener, addPopupMenuListener, configureEditor, configurePropertiesFromAction, contentsChanged, createActionPropertyChangeListener, createDefaultKeySelectionManager, fireActionEvent, fireItemStateChanged, firePopupMenuCanceled, firePopupMenuWillBecomeInvisible, firePopupMenuWillBecomeVisible, getAccessibleContext, getAction, getActionCommand, getActionListeners, getEditor, getItemAt, getItemCount, getItemListeners, getKeySelectionManager, getMaximumRowCount, getModel, getPopupMenuListeners, getPrototypeDisplayValue, getRenderer, getSelectedIndex, getSelectedObjects, getUI, getUIClassID, hidePopup, insertItemAt, installAncestorListener, intervalAdded, intervalRemoved, isEditable, isLightWeightPopupEnabled, isPopupVisible, paramString, processKeyEvent, removeActionListener, removeAllItems, removeItem, removeItemAt, removeItemListener, removePopupMenuListener, selectedItemChanged, selectWithKeyChar, setAction, setActionCommand, setEditable, setEditor, setEnabled, setKeySelectionManager, setLightWeightPopupEnabled, setMaximumRowCount, setModel, setPopupVisible, setPrototypeDisplayValue, setRenderer, setSelectedIndex, setUI, showPopup, updateUI

 

Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update

 

Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree

 

Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle

 

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

 

Field Detail

validator

protected AbstractPicker.PickerResultValidator validator

encoder

protected AbstractPicker.PickerValueEncoder encoder

Constructor Detail

AbstractPicker

public AbstractPicker()

Method Detail

getValidator

public AbstractPicker.PickerResultValidator getValidator()
Retrieve the PickerResultValidator used by this AbstractPicker to validate the results of Browse actions.
Returns:
the PickerResultValidator which the AbstractPicker will use to validate results.

setValidator

public void setValidator(AbstractPicker.PickerResultValidator newValidator)
Set the Validator used by this AbstractPicker.
Parameters:
newValidator - the PickerResultValidator which this AbstractPicker should use to validate results.

getEncoder

public AbstractPicker.PickerValueEncoder getEncoder()
Retrieve the Encoder used by this AbstractPicker.
Returns:
the PickerValueEncoder which this AbstractPicker will use to encode values.

setEncoder

public void setEncoder(AbstractPicker.PickerValueEncoder newEncoder)
Set the Encoder used by this AbstractPicker.
Parameters:
newEncoder - the PickerValueEncoder which this AbstractPicker should use to encode results.

getCurrentValue

public java.lang.Object getCurrentValue()

getSelectedItem

public java.lang.Object getSelectedItem()
Overrides:
getSelectedItem in class javax.swing.JComboBox

setCurrentValue

public void setCurrentValue(java.lang.Object newCurrentValue)

setSelectedItem

public void setSelectedItem(java.lang.Object newValue)
Overrides:
setSelectedItem in class javax.swing.JComboBox

getInvalidValueErrorTitle

protected java.lang.String getInvalidValueErrorTitle()
Retrieves the title string to use in the error dialog when the entered value is invalid. By default, it is 'Invalid Value'.

getInvalidValueErrorHelpID

protected java.lang.String getInvalidValueErrorHelpID()
Retrieves the HelpID string to use in the error dialog shown when the entered value is invalid. A value of null means that no Help button should be displayed.

setBrowseResult

public final void setBrowseResult(java.lang.Object result)
Set the value resulting from a Browse. If the Validator for this AbstractPicker is assigned, it will be used to validate the value. If the value is not valid, the Validator's getInvalidValueMsg method will be called to provide an error message. If the value is valid, the Encoder (if assigned) will be used to encode the value. This encoded value is then added to the model and selected.
Parameters:
result - the result of the Browse operation. If result is null, nothing is done. A non-null result is passed to the optional PickerResultValidator, the optional PickerValueEncoder, and then added to the model.

addValue

protected void addValue(java.lang.Object value)
Adds the value to the model. The default behavior is to check the model to see if the value already exists, and only add it if it does not. Subclasses can override addValue to change this behavior. Clients should interact directly with the model.
Parameters:
value - the new value (optionally encoded) to be added.

requestFocus

public void requestFocus()
Overrides:
requestFocus in class javax.swing.JComponent

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent ae)
Specified by:
actionPerformed in interface java.awt.event.ActionListener
Overrides:
actionPerformed in class javax.swing.JComboBox

doBrowse

protected abstract void doBrowse()

Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.2.0)

E17493-03


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