0

I've been working on a custom Javadoc doclet using the current doclet APIs. Having encountered a ReferenceTree for a link, let's say jdk.javadoc.doclet.Doclet#init(Locale, Reporter), I need to work out what classes Locale and Reporter correspond to. I can search in jdk.javadoc.doclet for Reporter and find it. But in order to find Locale I need to know that java.util.Locale was imported and I can't for the life of me work out how.

I even resorted to digging through the source for the standard doclet, but that's full of code that uses APIs that aren't exposed.

Can this be done using the public APIs?

I mean, I suppose I can search through all the classes in all the packages in all the modules in the DocletEnvironment, but if I don't find a unique answer, it'll be unclear how to decide which answer is correct if I can't find out what was imported.

Norm
  • 866
  • 1
  • 7
  • 16

0 Answers0