Package org.eclipse.search.ui.text
Class TextSearchQueryProvider.TextSearchInput
java.lang.Object
org.eclipse.search.ui.text.TextSearchQueryProvider.TextSearchInput
- Enclosing class:
TextSearchQueryProvider
Specified the input for a search query.
Clients may instantiate this class.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract FileTextSearchScopegetScope()Returns the scope for the searchabstract StringReturns the search text to search for.abstract booleanReturns whether the search is a case sensitive search or not.abstract booleanReturns whether the search text denotes a regular expression or not.booleanReturns whether to require a word boundary at the beginning and end of the pattern, excluding matches that only match part of a word.booleanReturns whether binary files are searched.
-
Constructor Details
-
TextSearchInput
public TextSearchInput()
-
-
Method Details
-
getSearchText
Returns the search text to search for.- Returns:
- the search text, depending on
isRegExSearch()the search text represents a regular expression or a pattern using '*' and '?' as wildcards. The empty search text signals a file name search.
-
isCaseSensitiveSearch
public abstract boolean isCaseSensitiveSearch()Returns whether the search is a case sensitive search or not.- Returns:
- whether the pattern is to be used case sensitive or not.
-
isRegExSearch
public abstract boolean isRegExSearch()Returns whether the search text denotes a regular expression or not.- Returns:
- whether the pattern denotes a regular expression.
-
isWholeWordSearch
public boolean isWholeWordSearch()Returns whether to require a word boundary at the beginning and end of the pattern, excluding matches that only match part of a word. This implementation returnsfalse, subclasses can override.- Returns:
trueif the pattern should match only whole words.trueis not allowed ifisRegExSearch()returnstrue. In this case, clients can either ignore this option or throw anIllegalArgumentException.- Since:
- 3.9
-
searchInBinaries
public boolean searchInBinaries()Returns whether binary files are searched. This implementation returnsfalse, subclasses can override.- Returns:
trueif binary files are searched- Since:
- 3.11
-
getScope
Returns the scope for the search- Returns:
- the scope for the search
-