public abstract static class PsiReferenceBase.Poly<T extends PsiElement> extends PsiReferenceBase<T> implements PsiPolyVariantReference
PsiReferenceBase.Immediate<T extends PsiElement>, PsiReferenceBase.Poly<T extends PsiElement>
myElement, mySoft
ARRAY_FACTORY, EMPTY_ARRAY
Constructor and Description |
---|
Poly(T psiElement) |
Poly(T element,
boolean soft) |
Poly(T element,
TextRange rangeInElement,
boolean soft) |
Modifier and Type | Method and Description |
---|---|
boolean |
isReferenceTo(PsiElement element)
Checks if the reference targets the specified element.
|
PsiElement |
resolve()
Returns the element which is the target of the reference.
|
bindToElement, calculateDefaultRangeInElement, createSelfReference, createSelfReference, getCanonicalText, getElement, getRangeInElement, getValue, handleElementRename, isSoft, setRangeInElement, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
multiResolve, resolveReference
bindToElement, getCanonicalText, getElement, getRangeInElement, getVariants, handleElementRename, isSoft, resolvesTo
getAbsoluteRange
public boolean isReferenceTo(PsiElement element)
PsiReference
isReferenceTo
in interface PsiReference
isReferenceTo
in class PsiReferenceBase<T extends PsiElement>
element
- the element to check target for.true
if the reference targets that element, false
otherwise.public PsiElement resolve()
PsiReference
resolve
in interface PsiReference
null
if it was not possible to resolve the reference to a valid target.PsiPolyVariantReference.multiResolve(boolean)