This page is no longer maintained — Please continue to the home page at www.scala-lang.org

How to use Scaladoc model or ast to find direct superclasses/supertraits

1 reply
Ken McDonald
Joined: 2011-02-13,
User offline. Last seen 42 years 45 weeks ago.

At the moment, I'm hacking scaladoc in the 2.8.1 trunk to try to add
graphs to scaladoc output. In the inheritance graph, I'd like to show
not only the linearization for a class/trait, but also the declarative
structure; similar to what is done in fig. 12.1 in the Programming in
Scala (2nd ed.) book.

Using the scaladoc model classes (..Entity and related) I don't see an
obvious way of doing this. Do I need to go into the compiler symbol
table and internals, or am I missing something simple? I don't really
want to dive into the compiler structures unless I have to...

Thanks,
Ken

Ken McDonald
Joined: 2011-02-13,
User offline. Last seen 42 years 45 weeks ago.
Re: How to use Scaladoc model or ast to find direct superclasses

Oops, sorry, think I found the answer whilst browsing the scaladoc
classes. I hadn't yet become familiar with all the subclasses of
DocTemplateEntity. Would've been nice to have an inheritance graph
showing them :-)

Copyright © 2012 École Polytechnique Fédérale de Lausanne (EPFL), Lausanne, Switzerland