Interface IParallelizable
- All Known Implementing Classes:
AbstractJavaSearchScope,AbstractSearchScope,AndPattern,ConstructorDeclarationPattern,ConstructorPattern,DeclarationOfAccessedFieldsPattern,DeclarationOfReferencedMethodsPattern,DeclarationOfReferencedTypesPattern,FieldPattern,HierarchyScope,IntersectingPattern,JavaSearchParticipant,JavaSearchPattern,JavaSearchScope,JavaWorkspaceScope,LocalVariablePattern,MethodDeclarationPattern,MethodPattern,ModulePattern,MultiTypeDeclarationPattern,OrPattern,PackageDeclarationPattern,PackageReferencePattern,QualifiedTypeDeclarationPattern,SecondaryTypeDeclarationPattern,SuperTypeReferencePattern,TypeDeclarationPattern,TypeParameterPattern,TypeReferencePattern,UnindexedSearchScope,VariablePattern
public interface IParallelizable
This interface can be used by
IJavaSearchScope, JavaSearchParticipant and SearchPattern to
mark implementors as eligible for parallel index search.- Since:
- 3.25
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidinitBeforeSearch(org.eclipse.core.runtime.IProgressMonitor monitor) Initialize all needed data before search is startedbooleanAnswerstrueif the current instance supports parallel index searchstatic booleanChecks if the given object implements this interface and also returnstrueforisParallelSearchSupported().
-
Method Details
-
isParallelSearchSupported
boolean isParallelSearchSupported()Answerstrueif the current instance supports parallel index search- Returns:
- Returns
trueif the implementation is safe to be used in a parallel search.
-
initBeforeSearch
default void initBeforeSearch(org.eclipse.core.runtime.IProgressMonitor monitor) throws JavaModelException Initialize all needed data before search is started- Parameters:
monitor- non null progress callback- Throws:
JavaModelException
-
isParallelSearchSupported
Checks if the given object implements this interface and also returnstrueforisParallelSearchSupported().- Parameters:
o- The object that needs to be checked.nullvalue will result in returningfalse.- Returns:
trueif the given object can be used in parallel search.
-