PsiElement.getReferences

could someone who knows (or believes to know :-P) the answer please clarify:

PsiElement.getReferences should return:

a) data about "this" element (possibly qualifiers + name)
b) data about the declaration "this" element links to (possibly separate references to qualifier (module) & to the name (function))
c) ...

?

2 comments
Comment actions Permalink

As documented in the javadoc of the getReferences() method, it returns the references from this element to other elements. A qualified name is typically represented by multiple PSI elements, but if it's not (for example, if you have a qualified name in a string literal), then you will indeed have separate references to each part of the qualifier and to the name itself.

0
Comment actions Permalink

> references from this element to other elements

all other elements or only declarations?

Thank you very much Dmitry!

0

Please sign in to leave a comment.