1 11 12 package org.eclipse.search.ui.text; 13 14 import org.eclipse.core.runtime.CoreException; 15 16 import org.eclipse.core.resources.IResource; 17 18 import org.eclipse.ui.IWorkingSet; 19 20 import org.eclipse.search.ui.ISearchQuery; 21 22 import org.eclipse.search.internal.ui.SearchPlugin; 23 24 31 public abstract class TextSearchQueryProvider { 32 33 39 public static abstract class TextSearchInput { 40 41 47 public abstract String getSearchText(); 48 49 54 public abstract boolean isCaseSensitiveSearch(); 55 56 61 public abstract boolean isRegExSearch(); 62 63 68 public abstract FileTextSearchScope getScope(); 69 70 } 71 72 80 public static TextSearchQueryProvider getPreferred() { 81 return SearchPlugin.getDefault().getTextSearchQueryProviderRegistry().getPreferred(); 82 } 83 84 92 public abstract ISearchQuery createQuery(TextSearchInput textSearchInput) throws CoreException; 93 94 102 public abstract ISearchQuery createQuery(String selectedText) throws CoreException; 103 104 113 public abstract ISearchQuery createQuery(String selectedText, IResource[] resources) throws CoreException; 114 115 124 public abstract ISearchQuery createQuery(String selectedText, IWorkingSet[] ws) throws CoreException; 125 } 126 | Popular Tags |