-
Bug
-
Resolution: Duplicate
-
P4
-
None
-
1.3.0
-
x86
-
windows_nt
Name: skT45625 Date: 06/05/2000
java version "1.3.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.0-C)
Java HotSpot(TM) Client VM (build 1.3.0-C, mixed mode)
javadoc (when run with the -private option) does not generate any documentation
for private member classes except for the signature of the class and the methods
inherited from java.lang.Object. No fields, methods, inner classes are
documented (neither summary nor detail) no matter whether those fields, etc.
have public, protected, package, or private access.
Example: save the following (minimized) class to some directory, cd to that
directory, compile it with "javac FileTree.java" and afterwards run "javadoc
-private FileTree" and take a look at "FileTree.FTEnum.html". There should be
documentation for 'private class FTElem', 'private FTElem rCurrent', 'private
FTEnum ( int flags )', 'public boolean hasMoreElements ( )', 'public Object
nextElement ( )', but there is not. Note that it doesn't matter whether the
missing elements are private (as the first 3 ones), package, protected, or
public (as the last 2 ones).
----snip----
import java.io.*;
import java.util.*;
/** FileTree can be used to retrieve and traverse the contents of a
* directory and all its subdirectories recursively. Entries will be
* returned as Strings specifying an absolute path or a path relative to
* the specified directory. The order in which the entries will be
* traversed can be specified to some extent.
*
* @author Christian Rattei <###@###.###>
* @version 1.1, 06/01/00
*/
public final class FileTree
{
/** This class enumerates all entries according to flags that specify
* which entries should be returned and in which order.
*/
private class FTEnum implements Enumeration
{
/** This class represents one element in the enumeration chain. */
private class FTElem
{
/** The represented file tree element. */
private FileTree rFile;
/** Constructor that puts the new entry to the end of the chain.
*
* @param file element to be enchained. May not be null.
*/
private FTElem ( FileTree file )
{
}
}
/** Current element in the enumeration. */
private FTElem rCurrent;
/** Creates an enumeration depending on the specified flags.
*
* @param flags any sensible combination of <code>FILES</code>,
* <code>DIRS</code>, <code>SUB_DIRS_FIRST</code>,
* <code>SUB_DIRS_LAST</code>,
* <code>EXCLUDE_EMPTY_DIRS</code>, and
* <code>ABSOLUTE_NAMES</code>.
* <code>SUB_DIRS_FIRST</code> and
* <code>SUB_DIRS_LAST</code> specify the order of files
* and directories within each directory. If you e. g.
* need e. g. all directories before all files then
* create two enumerations, one with <code>DIRS</code>
* only and one with <code>FILES</code> only.
*/
private FTEnum ( int flags )
{
}
/** Returns whether there are more entries to be processed.
*
* @return true if more elemets are available, else false.
*/
public boolean hasMoreElements ( )
{
return (rCurrent != null);
}
/** Returns the next available element.
*
* @return a string describing a path to the next element. Whether
* this path is absolute or relative depends on the flags
* with which this enumeration was created.
* @throws java.util.NoSuchElementException if no more elements are
* available.
*/
public Object nextElement ( )
{
return null;
}
}
/** Parent file tree. */
private FileTree rParent;
/** Constructs a file tree from a string.
*
* @param pathname should point to an existing directory. If it points
* to a file rather than a directory or to a non
* existing file the file tree will be empty. May not be
* null.
*/
public FileTree ( String pathname )
{
this(null, new File(pathname));
}
/** Constructs a (sub) file tree and connects it to the specified
* parent file tree.
*
* @param parent the parent file tree of this one. May be null to
* indicate the root of the tree.
* @param path the fully qualified path name to this file if parent
* is null, else only the file name.
*/
private FileTree ( FileTree parent, File path )
{
}
/** Returns an enumeration of all elements of this file tree. Multiple
* enumerations with possibly different flags for the same file tree can
* coexist at the same time.
*
* @param flags any sensible combination of <code>FILES</code>,
* <code>DIRS</code>, <code>SUB_DIRS_FIRST</code>,
* <code>SUB_DIRS_LAST</code>,
* <code>EXCLUDE_EMPTY_DIRS</code>, and
* <code>ABSOLUTE_NAMES</code>.<br>
* <code>SUB_DIRS_FIRST</code> and
* <code>SUB_DIRS_LAST</code> specify the order of files
* and directories within each directory. If you e. g. need
* all directories before all files then create two
* enumerations, one with <code>DIRS</code> only and one
* with <code>FILES</code> only.<br>
* If both <code>FILES</code> and <code>DIRS</code> are
* specified the path of every subdirectory will always be
* returned before the first file in that directory
* (independently of the remaining flags).
*/
public Enumeration elements ( int flags )
{
return new FTEnum(flags);
}
}
----snap----
(Review ID: 105709)
======================================================================
java version "1.3.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.0-C)
Java HotSpot(TM) Client VM (build 1.3.0-C, mixed mode)
javadoc (when run with the -private option) does not generate any documentation
for private member classes except for the signature of the class and the methods
inherited from java.lang.Object. No fields, methods, inner classes are
documented (neither summary nor detail) no matter whether those fields, etc.
have public, protected, package, or private access.
Example: save the following (minimized) class to some directory, cd to that
directory, compile it with "javac FileTree.java" and afterwards run "javadoc
-private FileTree" and take a look at "FileTree.FTEnum.html". There should be
documentation for 'private class FTElem', 'private FTElem rCurrent', 'private
FTEnum ( int flags )', 'public boolean hasMoreElements ( )', 'public Object
nextElement ( )', but there is not. Note that it doesn't matter whether the
missing elements are private (as the first 3 ones), package, protected, or
public (as the last 2 ones).
----snip----
import java.io.*;
import java.util.*;
/** FileTree can be used to retrieve and traverse the contents of a
* directory and all its subdirectories recursively. Entries will be
* returned as Strings specifying an absolute path or a path relative to
* the specified directory. The order in which the entries will be
* traversed can be specified to some extent.
*
* @author Christian Rattei <###@###.###>
* @version 1.1, 06/01/00
*/
public final class FileTree
{
/** This class enumerates all entries according to flags that specify
* which entries should be returned and in which order.
*/
private class FTEnum implements Enumeration
{
/** This class represents one element in the enumeration chain. */
private class FTElem
{
/** The represented file tree element. */
private FileTree rFile;
/** Constructor that puts the new entry to the end of the chain.
*
* @param file element to be enchained. May not be null.
*/
private FTElem ( FileTree file )
{
}
}
/** Current element in the enumeration. */
private FTElem rCurrent;
/** Creates an enumeration depending on the specified flags.
*
* @param flags any sensible combination of <code>FILES</code>,
* <code>DIRS</code>, <code>SUB_DIRS_FIRST</code>,
* <code>SUB_DIRS_LAST</code>,
* <code>EXCLUDE_EMPTY_DIRS</code>, and
* <code>ABSOLUTE_NAMES</code>.
* <code>SUB_DIRS_FIRST</code> and
* <code>SUB_DIRS_LAST</code> specify the order of files
* and directories within each directory. If you e. g.
* need e. g. all directories before all files then
* create two enumerations, one with <code>DIRS</code>
* only and one with <code>FILES</code> only.
*/
private FTEnum ( int flags )
{
}
/** Returns whether there are more entries to be processed.
*
* @return true if more elemets are available, else false.
*/
public boolean hasMoreElements ( )
{
return (rCurrent != null);
}
/** Returns the next available element.
*
* @return a string describing a path to the next element. Whether
* this path is absolute or relative depends on the flags
* with which this enumeration was created.
* @throws java.util.NoSuchElementException if no more elements are
* available.
*/
public Object nextElement ( )
{
return null;
}
}
/** Parent file tree. */
private FileTree rParent;
/** Constructs a file tree from a string.
*
* @param pathname should point to an existing directory. If it points
* to a file rather than a directory or to a non
* existing file the file tree will be empty. May not be
* null.
*/
public FileTree ( String pathname )
{
this(null, new File(pathname));
}
/** Constructs a (sub) file tree and connects it to the specified
* parent file tree.
*
* @param parent the parent file tree of this one. May be null to
* indicate the root of the tree.
* @param path the fully qualified path name to this file if parent
* is null, else only the file name.
*/
private FileTree ( FileTree parent, File path )
{
}
/** Returns an enumeration of all elements of this file tree. Multiple
* enumerations with possibly different flags for the same file tree can
* coexist at the same time.
*
* @param flags any sensible combination of <code>FILES</code>,
* <code>DIRS</code>, <code>SUB_DIRS_FIRST</code>,
* <code>SUB_DIRS_LAST</code>,
* <code>EXCLUDE_EMPTY_DIRS</code>, and
* <code>ABSOLUTE_NAMES</code>.<br>
* <code>SUB_DIRS_FIRST</code> and
* <code>SUB_DIRS_LAST</code> specify the order of files
* and directories within each directory. If you e. g. need
* all directories before all files then create two
* enumerations, one with <code>DIRS</code> only and one
* with <code>FILES</code> only.<br>
* If both <code>FILES</code> and <code>DIRS</code> are
* specified the path of every subdirectory will always be
* returned before the first file in that directory
* (independently of the remaining flags).
*/
public Enumeration elements ( int flags )
{
return new FTEnum(flags);
}
}
----snap----
(Review ID: 105709)
======================================================================
- duplicates
-
JDK-4456112 stddoclet: javadoc does not document fields/methods for private inner classes
-
- Closed
-