I work on a relatively complex Java project where classes commonly have four or five ancestors before Object
. Given such a class, eg D
in a hierarchy like this: Object > A > B > C > D
, I would like to know what all interfaces it effectively implements. That is, I am also interested in seeing that D
implements, say, Serializable
even if that is declared only in the declaration of class B
and even when D
does not actually implement any of the methods specified by the interface (naturally, if talking about Serializable
).
Some potential sources of this information I tried include:
Is there a way to obtain this information in IDEA without having to open files of all ancestor classes of the class in question?
If you are fine with UML representation, then use
Press ⌥⇧⌘U
or ⌥⌘U
on mac
Press Ctrl+Shift+Alt+U
or Ctrl+Alt+U
on default windows keymap
See https://www.jetbrains.com/help/idea/2016.3/viewing-class-hierarchy-as-a-class-diagram.html
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.