public class GotoFileItemProvider extends DefaultChooseByNameItemProvider
DefaultChooseByNameItemProvider.PathProximityComparator
Constructor and Description |
---|
GotoFileItemProvider(Project project,
PsiElement context,
GotoFileModel model) |
Modifier and Type | Method and Description |
---|---|
boolean |
filterElementsWithWeights(ChooseByNameBase base,
FindSymbolParameters parameters,
ProgressIndicator indicator,
Processor<? super FoundItemDescriptor<?>> consumer)
Searches for elements that match specified filters and returns also their weights.
|
static MinusculeMatcher |
getQualifiedNameMatcher(java.lang.String pattern) |
static java.lang.String |
getSanitizedPattern(java.lang.String pattern,
GotoFileModel model) |
filterElements, filterElements, filterElements, filterElementsWithWeights, filterNames, getPathProximityComparator, matches
public GotoFileItemProvider(Project project, PsiElement context, GotoFileModel model)
public boolean filterElementsWithWeights(ChooseByNameBase base, FindSymbolParameters parameters, ProgressIndicator indicator, Processor<? super FoundItemDescriptor<?>> consumer)
ChooseByNameInScopeItemProvider
FindSymbolParameters
)
Method should be used when receiver wants to sort found items by itself (for example when they should be mixed with results from other providers)filterElementsWithWeights
in interface ChooseByNameInScopeItemProvider
filterElementsWithWeights
in class DefaultChooseByNameItemProvider
parameters
- search parametersindicator
- ProgressIndicator
which could be used to cancel search processconsumer
- consumer for process all found items. Takes instances of FoundItemDescriptor
wrapper, which contains also
item's wightstrue
if all found items were processed. If consumer
returns false
for any of them search will be
stopped and method will return false
FindSymbolParameters
,
FoundItemDescriptor
public static java.lang.String getSanitizedPattern(java.lang.String pattern, GotoFileModel model)
public static MinusculeMatcher getQualifiedNameMatcher(java.lang.String pattern)