|
Extension SDK 10.1.2 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JList oracle.javatools.editor.insight.TooltipInsightView
The TooltipInsightView
class is an implementation of
the InsightView
to support tooltip insight using a
list-type data model. The data is displayed inside a JList and
rendered with a custom list cell renderer if one is provided.
The default implementation of TooltipDataItemCellRenderer
can be used, which will render the list cells with just a plain
label.
The TooltipInsightData
can be used as an abstract
starting point for your own InsightData
implementation,
but is not required. Your implementation must however implement
the ListInsightData
interface, since this view is
based on a list model. You may wish to make use of the provided
TooltipDataItemListModel
to take care of
ListModel
functionality for convenience.
InsightView
,
TooltipInsightData
,
TooltipDataItem
,
TooltipDataItemCellRenderer
,
Serialized FormNested Class Summary |
Nested classes inherited from class javax.swing.JList |
javax.swing.JList.AccessibleJList |
Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary |
Fields inherited from class javax.swing.JList |
HORIZONTAL_WRAP, VERTICAL, VERTICAL_WRAP |
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 | |
TooltipInsightView()
Constructs a new TooltipInsightView with no custom cell
renderer. |
|
TooltipInsightView(javax.swing.ListCellRenderer renderer)
Constructs a new TooltipInsightView with no data,
but with the specified cell renderer. |
|
TooltipInsightView(ListInsightData insightData)
Constructs a new TooltipInsightView with the given
insight data, but no cell renderer. |
|
TooltipInsightView(ListInsightData insightData,
javax.swing.ListCellRenderer renderer)
Constructs a new TooltipInsightView with the given
insight data and cell renderer. |
Method Summary | |
boolean |
begin()
Command to move the selection of the view to the top of the data set. |
boolean |
complete(Insight insight)
Command to accept (complete) the current insight selection into the document. |
boolean |
down()
Command to move the selection of the view to the next item (down) in the data set. |
boolean |
end()
Command to move the selection of the view to the bottom of the data set. |
javax.swing.JComponent |
getComponent()
Fetches the Swing UI component for displaying this view. |
InsightData |
getData()
Fetches the InsightData that is the data model associated with this particular view. |
boolean |
left()
Command to move the selection of the view to the left item in the data set. |
boolean |
pageDown()
Command to move the selection of the view down by one page in the data set. |
boolean |
pageUp()
Command to move the selection of the view up by one page in the data set. |
boolean |
partialComplete()
Command to request partial completion using the current insight information based on the current document contents. |
boolean |
right()
Command to move the selection of the view to the right item in the data set. |
void |
selectDefault()
Instructs the InsightView to select the default insight data item, and to make sure that it is visible. |
void |
setData(InsightData newData)
Sets the InsightData data model which should be displayed by this view. |
void |
setPopupWindow(oracle.javatools.editor.popup.PopupWindow popup)
Sets the PopupWindow so we can set the accessible name of the
selected item on the window so it will be read. |
void |
setUI(javax.swing.plaf.ListUI ui)
Sets the look and feel (L&F) object that renders this component. |
boolean |
up()
Command to move the selection of the view to the previous item (up) in the data set. |
Methods inherited from class javax.swing.JList |
addListSelectionListener, addSelectionInterval, clearSelection, createSelectionModel, ensureIndexIsVisible, fireSelectionValueChanged, getAccessibleContext, getAnchorSelectionIndex, getCellBounds, getCellRenderer, getDragEnabled, getFirstVisibleIndex, getFixedCellHeight, getFixedCellWidth, getLastVisibleIndex, getLayoutOrientation, getLeadSelectionIndex, getListSelectionListeners, getMaxSelectionIndex, getMinSelectionIndex, getModel, getNextMatch, getPreferredScrollableViewportSize, getPrototypeCellValue, getScrollableBlockIncrement, getScrollableTracksViewportHeight, getScrollableTracksViewportWidth, getScrollableUnitIncrement, getSelectedIndex, getSelectedIndices, getSelectedValue, getSelectedValues, getSelectionBackground, getSelectionForeground, getSelectionMode, getSelectionModel, getToolTipText, getUI, getUIClassID, getValueIsAdjusting, getVisibleRowCount, indexToLocation, isSelectedIndex, isSelectionEmpty, locationToIndex, paramString, removeListSelectionListener, removeSelectionInterval, setCellRenderer, setDragEnabled, setFixedCellHeight, setFixedCellWidth, setLayoutOrientation, setListData, setListData, setModel, setPrototypeCellValue, setSelectedIndex, setSelectedIndices, setSelectedValue, setSelectionBackground, setSelectionForeground, setSelectionInterval, setSelectionMode, setSelectionModel, setValueIsAdjusting, setVisibleRowCount, updateUI |
Methods inherited from class javax.swing.JComponent |
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, 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, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, 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, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, 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, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, 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 |
Constructor Detail |
public TooltipInsightView()
TooltipInsightView
with no custom cell
renderer. This will just construct an empty list with our
default TooltipDataItemCellRenderer
public TooltipInsightView(javax.swing.ListCellRenderer renderer)
TooltipInsightView
with no data,
but with the specified cell renderer. Since the data list
is empty, the data to be displayed must be set with a separate
call to setData() to display any data.
renderer
- the cell renderer to usepublic TooltipInsightView(ListInsightData insightData)
TooltipInsightView
with the given
insight data, but no cell renderer. This will render the list
with the Swing default list cell renderer. The cell renderer may
be changed later with a call to setCellRenderer()
with the appropriate cell renderer to use.
insightData
- the insight data to use for the data modelpublic TooltipInsightView(ListInsightData insightData, javax.swing.ListCellRenderer renderer)
TooltipInsightView
with the given
insight data and cell renderer.
renderer
- the cell renderer to useinsightData
- the insight data to use for the data modelMethod Detail |
public void setUI(javax.swing.plaf.ListUI ui)
ui
- the ListUI L&F objectpublic void setPopupWindow(oracle.javatools.editor.popup.PopupWindow popup)
PopupWindow
so we can set the accessible name of the
selected item on the window so it will be read.
setPopupWindow
in interface InsightView
public void setData(InsightData newData)
setData
in interface InsightView
newData
- the data model to usepublic void selectDefault()
setData()
before the actual view is even visible.
selectDefault
in interface InsightView
public InsightData getData()
getData
in interface InsightView
public javax.swing.JComponent getComponent()
getComponent
in interface InsightView
public boolean up()
up
in interface InsightView
public boolean down()
down
in interface InsightView
public boolean right()
right
in interface InsightView
public boolean left()
left
in interface InsightView
public boolean pageUp()
pageUp
in interface InsightView
public boolean pageDown()
pageDown
in interface InsightView
public boolean begin()
begin
in interface InsightView
public boolean end()
end
in interface InsightView
public boolean complete(Insight insight)
InsightView
complete
in interface InsightView
insight
- the main Insight engine for the purpose of
hiding or re-triggering Insight
public boolean partialComplete()
partialComplete
in interface InsightView
|
Extension SDK | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 1997, 2004, Oracle. All rights reserved.