|
Extension SDK 10.1.2 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The InsightView
interface acts as the view and
controller for the Insight. Information that is retrieved from the
InsightProvider is passed on to the InsightView which is
responsible for constructing a Swing UI component to represent the
data. Additionally, Insight commands (navigation, completion
acceptance) are passed on to the InsightView to delegate as
appropriate.
Note that all of the commands defined by this interface return a
boolean value. This is because certain commands only make sense
with certain Insight features. For example, if a given Insight
implementation only provides tooltip assistance, then
accept()
and partial()
should return
false since completion assistance is not applicable.
Insight
,
InsightProvider
,
InsightData
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 insightData)
Sets the InsightData data model which should be displayed by this view. |
void |
setPopupWindow(oracle.javatools.editor.popup.PopupWindow popupWindow)
Sets the PopupWindow which will contain the InsightView
This is necessary so the InsightView can set the accessible name
on the window so it will be read. |
boolean |
up()
Command to move the selection of the view to the previous item (up) in the data set. |
Method Detail |
public void setData(InsightData insightData)
insightData
- the data model to usepublic InsightData getData()
public void selectDefault()
setData()
before the actual view is even visible.
public javax.swing.JComponent getComponent()
public boolean up()
For example, suppose the underlying Insight implements completion insight, and the view is a List. The view should return true here even if the selection is at the top of the list since the view supports navigation upwards and downwards.
public boolean down()
public boolean right()
right()
and left()
actions are here to support views where the concept of right and
left makes sense, such as a tree view.
public boolean left()
right()
and left()
actions are here to support views where the concept of right and
left makes sense, such as a tree view.
public boolean pageUp()
public boolean pageDown()
public boolean begin()
public boolean end()
public boolean complete(Insight insight)
insight
- the main Insight engine for the purpose of
hiding or re-triggering Insight
public boolean partialComplete()
Hitting "Tab" will enter "ual" into the document so that the user's document now reads "s.equal". The Insight information should also be updated to reflect the new document contents.
Even if there is only one selection applicable to the partial match, this will not perform an "accept". It is up to the user to hit "Enter" to accept the single selection applicable.
public void setPopupWindow(oracle.javatools.editor.popup.PopupWindow popupWindow)
PopupWindow
which will contain the InsightView
This is necessary so the InsightView
can set the accessible name
on the window so it will be read.
|
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.