com.intellij.psi
Interface PsiPolyVariantReference
- All Superinterfaces:
- PsiReference
- All Known Subinterfaces:
- PsiImportStaticReferenceElement, PsiJavaCodeReferenceElement, PsiJavaReference, PsiReferenceExpression
public interface PsiPolyVariantReference
- extends PsiReference
Inherit this interface if you want the reference to resolve to more than one element,
or if you want to provide resolve result(s) for a superset of valid resolve cases.
e.g. in java references in static context are resolved to nonstatic methods in case
there is no valid candidate. isValidResult() in this case should return false
for later analysis by highlighting pass.
multiResolve
@NotNull
ResolveResult[] multiResolve(boolean incompleteCode)
- Returns the results of resolving the reference.
- Parameters:
incompleteCode - if true, the code in the context of which the reference is
being resolved is considered incomplete, and the method may return additional
invalid results.
- Returns:
- the array of results for resolving the reference.