public final class CallHierarchyNodeDescriptor extends HierarchyNodeDescriptor implements Navigatable
NodeDescriptor.NodeComparator<T extends NodeDescriptor<?>>myHighlightedText, myIsBaseDEFAULT_WEIGHT, EMPTY_ARRAY, myClosedIcon, myColor, myName, myOpenIcon, myProject| Constructor and Description |
|---|
CallHierarchyNodeDescriptor(Project project,
HierarchyNodeDescriptor parentDescriptor,
PsiElement element,
boolean isBase,
boolean navigateToReference) |
| Modifier and Type | Method and Description |
|---|---|
void |
addReference(PsiReference reference) |
boolean |
canNavigate()
Indicates whether this instance supports navigation of any kind.
|
boolean |
canNavigateToSource()
Indicates whether this instance supports navigation to source (that means some kind of editor).
|
PsiMember |
getEnclosingElement() |
static PsiMember |
getEnclosingElement(PsiElement element) |
PsiElement |
getTargetElement()
Element for OpenFileDescriptor
|
boolean |
hasReference(PsiReference reference) |
void |
incrementUsageCount() |
boolean |
isValid() |
void |
navigate(boolean requestFocus)
Open editor and select/navigate to the object there if possible.
|
boolean |
update()
Make sure the descriptor is up to date with its content
|
expandOnDoubleClick, getBaseMarkerIcon, getCachedChildren, getContainingFile, getElement, getHighlightedText, getInvalidPrefixAttributes, getPackageNameAttributes, getUsageCountPrefixAttributes, installIcon, installIcon, installIcon, invalidElement, isMarkModified, isMarkReadOnly, setCachedChildrengetIcon, getPsiElementapplyFrom, getChildrenSortingStamp, getClosedIcon, getColor, getIcon, getIndex, getOpenIcon, getParentDescriptor, getProject, getUpdateCount, getWeight, isWasDeclaredAlwaysLeaf, setChildrenSortingStamp, setIcon, setIndex, setUpdateCount, setWasDeclaredAlwaysLeaf, toStringpublic CallHierarchyNodeDescriptor(Project project, HierarchyNodeDescriptor parentDescriptor, PsiElement element, boolean isBase, boolean navigateToReference)
public final PsiMember getEnclosingElement()
public static PsiMember getEnclosingElement(PsiElement element)
public final void incrementUsageCount()
public final PsiElement getTargetElement()
public final boolean isValid()
isValid in class HierarchyNodeDescriptorpublic final boolean update()
NodeDescriptorupdate in class SmartElementDescriptorpublic void addReference(PsiReference reference)
public boolean hasReference(PsiReference reference)
public void navigate(boolean requestFocus)
Navigatablenavigate in interface NavigatablerequestFocus - true if focus requesting is necessarypublic boolean canNavigate()
NavigatableNavigatable.canNavigateToSource() returns true.
We assume that this method should return true in such case,
so implement this method respectively.canNavigate in interface Navigatablefalse if navigation is not possible for any reason.public boolean canNavigateToSource()
Navigatablefalse.
In such cases it is not recommended to do batch navigation for all navigatables
available via CommonDataKeys.NAVIGATABLE_ARRAY,
because it may lead to opening several modal dialogs.
Use OpenSourceUtil.navigate(com.intellij.pom.Navigatable...) to process such arrays correctly.canNavigateToSource in interface Navigatablefalse if navigation to source is not possible for any reason.