forked from eclipse-platform/eclipse.platform.text
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds a search filter to search result View after first search. Press ENTER to get into the fine grained search Dialog. Providers have to implement IResearchQuery + some multithreading hardening of the search which pop up under that heavy load.
- Loading branch information
1 parent
c407b4a
commit 3334d01
Showing
10 changed files
with
389 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 52 additions & 0 deletions
52
org.eclipse.search/new search/org/eclipse/search/ui/IResearchQuery.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
/******************************************************************************* | ||
* Copyright (c) 2022 Joerg Kubitz and others. | ||
* | ||
* This program and the accompanying materials | ||
* are made available under the terms of the Eclipse Public License 2.0 | ||
* which accompanies this distribution, and is available at | ||
* https://www.eclipse.org/legal/epl-2.0/ | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
* | ||
* Contributors: | ||
* Joerg Kubitz - initial API and implementation | ||
*******************************************************************************/ | ||
package org.eclipse.search.ui; | ||
|
||
import org.eclipse.core.runtime.IProgressMonitor; | ||
|
||
/** | ||
* Represents a particular search query that can be rerun in background with an | ||
* updated search text | ||
* <p> | ||
* Clients may implement this interface. | ||
* </p> | ||
* | ||
* @since 3.15 | ||
*/ | ||
public interface IResearchQuery extends ISearchQuery { | ||
/** | ||
* @return the text the user was searching for | ||
*/ | ||
String getSearchString(); | ||
|
||
/** | ||
* Sets the search text for the next run | ||
* | ||
* @param s | ||
* the text the user is searching for | ||
* @see org.eclipse.search.ui.ISearchQuery#run(IProgressMonitor) | ||
*/ | ||
void setSearchString(String s); | ||
|
||
@Override | ||
public default boolean canRerun() { | ||
return true; | ||
} | ||
|
||
@Override | ||
public default boolean canRunInBackground() { | ||
return true; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.