|
Eclipse Platform Release 3.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.search.ui.NewSearchUI
A facade for access to the new search UI facilities.
Field Summary | |
static String |
ACTION_SET_ID
Id of the Search action set (value "org.eclipse.search.searchActionSet" ). |
static String |
PLUGIN_ID
Search Plug-in Id (value "org.eclipse.search" ). |
static String |
SEARCH_MARKER
Search marker type (value "org.eclipse.search.searchmarker" ). |
static String |
SEARCH_VIEW_ID
Id of the new Search view (value "org.eclipse.search.ui.views.SearchView" ). |
Constructor Summary | |
NewSearchUI()
|
Method Summary | |
static ISearchResultViewPart |
activateSearchResultView()
Activates a search result view in the current workbench window page. |
static void |
addQueryListener(IQueryListener l)
Registers the given listener to receive notification of changes to queries. |
static boolean |
arePotentialMatchesIgnored()
Returns the preference whether a search engine is allowed to report potential matches or not. |
static String |
getDefaultPerspectiveId()
Returns the ID of the default perspective. |
static ISearchQuery[] |
getQueries()
Returns all search queries know to the search UI (i.e. registered via runQuery() or runQueryInForeground()) . |
static ISearchResultViewPart |
getSearchResultView()
Gets the search result view shown in the current workbench window. |
static boolean |
isQueryRunning(ISearchQuery query)
Returns whether the given query is currently running. |
static void |
openSearchDialog(IWorkbenchWindow window,
String pageId)
Opens the search dialog. |
static void |
removeQueryListener(IQueryListener l)
Removes the given query listener. |
static boolean |
reuseEditor()
Returns the preference whether editors should be reused when showing search results. |
static void |
runQuery(ISearchQuery query)
Runs the given search query. |
static IStatus |
runQueryInForeground(IRunnableContext context,
ISearchQuery query)
Runs the given search query. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String PLUGIN_ID
"org.eclipse.search"
).
public static final String SEARCH_MARKER
"org.eclipse.search.searchmarker"
).
IMarker
,
Constant Field Valuespublic static final String SEARCH_VIEW_ID
"org.eclipse.search.ui.views.SearchView"
).
public static final String ACTION_SET_ID
"org.eclipse.search.searchActionSet"
).
Constructor Detail |
public NewSearchUI()
Method Detail |
public static ISearchResultViewPart activateSearchResultView()
null
if the
search result view couldn't be activatedpublic static ISearchResultViewPart getSearchResultView()
null
, if none is open
in the current workbench window pagepublic static void runQuery(ISearchQuery query)
ISearchQuery#canRunInBackground()
returns true
. Running a query adds it to the set of known
queries and notifies any registered IQueryListener
s about
the addition.
query
- the query to executepublic static IStatus runQueryInForeground(IRunnableContext context, ISearchQuery query)
IQueryListener
s about the addition.
context
- the runnable context to run the query inquery
- the query to execute
public static void addQueryListener(IQueryListener l)
l
- the listener to be addedpublic static void removeQueryListener(IQueryListener l)
l
- the listener to be removed.public static ISearchQuery[] getQueries()
runQuery()
or runQueryInForeground())
.
public static boolean isQueryRunning(ISearchQuery query)
query
- the query
runQuery(ISearchQuery)
,
runQueryInForeground(IRunnableContext, ISearchQuery)
public static void openSearchDialog(IWorkbenchWindow window, String pageId)
pageId
is specified and a corresponding page
is found then it is brought to top.
window
- the parent windowpageId
- the page to select or null
if the best fitting page should be selectedpublic static boolean reuseEditor()
true
if editors should be reused for showing search resultspublic static boolean arePotentialMatchesIgnored()
Search engines which can report inexact matches must
respect this preference i.e. they should not report
inexact matches if this method returns true
true
if search engine must not report inexact matchespublic static String getDefaultPerspectiveId()
The perspective with this ID will be used to show the Search view. If no default perspective is set then the Search view will appear in the current perspective.
null
if no default perspective is set
|
Eclipse Platform Release 3.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp. and others 2000, 2004. All rights reserved.