ALTE DOCUMENTE
|
|||
Conventions - Documenting Anonymous Classes
The Javadoc tool does not directly document anonymous classes - that is, their declarations and doc comments are ignored. If you want to 10310k1020k document an anonymous class, the proper way to do so is in a doc comment of its outer class, or another closely associated class.
For example, if you had an anonymous TreeSelectionListener inner class in a method makeTree that returns a JTree object that users of this class might want to override, you could document in the method comment that the returned JTree has a TreeSelectionListener attached to it:
* The method used for creating the tree. Any structural modifications
* to the display of the Jtree should be done by overriding this method.
* This method adds an anonymous TreeSelectionListener to the returned JTree.
* Upon receiving TreeSelectionEvents, this listener calls refresh with
* the selected node as a parameter.
*/
public JTree makeTree(AreaInfo ai)
|