summaryrefslogtreecommitdiff
path: root/libjava/classpath/tools/com/sun/javadoc
diff options
context:
space:
mode:
authorupstream source tree <ports@midipix.org>2015-03-15 20:14:05 -0400
committerupstream source tree <ports@midipix.org>2015-03-15 20:14:05 -0400
commit554fd8c5195424bdbcabf5de30fdc183aba391bd (patch)
tree976dc5ab7fddf506dadce60ae936f43f58787092 /libjava/classpath/tools/com/sun/javadoc
downloadcbb-gcc-4.6.4-554fd8c5195424bdbcabf5de30fdc183aba391bd.tar.bz2
cbb-gcc-4.6.4-554fd8c5195424bdbcabf5de30fdc183aba391bd.tar.xz
obtained gcc-4.6.4.tar.bz2 from upstream website;upstream
verified gcc-4.6.4.tar.bz2.sig; imported gcc-4.6.4 source tree from verified upstream tarball. downloading a git-generated archive based on the 'upstream' tag should provide you with a source tree that is binary identical to the one extracted from the above tarball. if you have obtained the source via the command 'git clone', however, do note that line-endings of files in your working directory might differ from line-endings of the respective files in the upstream repository.
Diffstat (limited to 'libjava/classpath/tools/com/sun/javadoc')
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/ClassDoc.java321
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/ConstructorDoc.java56
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/Doc.java264
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/DocErrorReporter.java76
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/Doclet.java98
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/ExecutableMemberDoc.java137
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/FieldDoc.java112
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/MemberDoc.java59
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/MethodDoc.java79
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/PackageDoc.java108
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/ParamTag.java65
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/Parameter.java87
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/ProgramElementDoc.java169
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/RootDoc.java111
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/SeeTag.java108
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/SerialFieldTag.java101
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/SourcePosition.java68
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/Tag.java106
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/ThrowsTag.java75
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/Type.java119
-rw-r--r--libjava/classpath/tools/com/sun/javadoc/TypeVariable.java73
21 files changed, 2392 insertions, 0 deletions
diff --git a/libjava/classpath/tools/com/sun/javadoc/ClassDoc.java b/libjava/classpath/tools/com/sun/javadoc/ClassDoc.java
new file mode 100644
index 000000000..6309f9472
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/ClassDoc.java
@@ -0,0 +1,321 @@
+/* ClassDoc.java -- Document a Java class or interface
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+public interface ClassDoc extends ProgramElementDoc, Type
+{
+
+/**
+ * This method tests whether or not the class represented by this object
+ * is abstract.
+ *
+ * @return <code>true</code> if the class is abstract, <code>false</code>,
+ * otherwise.
+ */
+public abstract boolean
+isAbstract();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not the class represented by this object
+ * is serializable. That is, whether or not the class implements the
+ * <code>java.io.Serializable</code> interface. This includes classes
+ * which are externalizable.
+ *
+ * @return <code>true</code> if the class is serializable,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isSerializable();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not the class represented by this object
+ * is externalizable. That is, whether or not the class implements the
+ * <code>java.io.Externalizable</code> interface.
+ *
+ * @return <code>true</code> if the class is externalizable,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isExternalizable();
+
+/*************************************************************************/
+
+/**
+ * This method returns the serialization methods for the class
+ * represented by this object. Is the custom readObject/writeObject
+ * methods?
+ *
+ * @return The serialization methods for this class.
+ */
+public abstract MethodDoc[]
+serializationMethods();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of fields that are serialized in this
+ * class. This will return either the list of fields with an
+ * "@serial" declaration, or, if it exists, the
+ * <code>serialPersistentField</code> field.
+ *
+ * @return The list of serializable fields.
+ */
+public abstract FieldDoc[]
+serializableFields();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not the class represented by this object
+ * specifically defines its serializable fields in a
+ * <code>serialPersistentFields</code> field.
+ *
+ * @return <code>true</code> if this class explicitly defines its
+ * serializable fields, <code>false</code> otherwise.
+ */
+public abstract boolean
+definesSerializableFields();
+
+/*************************************************************************/
+
+/**
+ * This method returns the superclass of the class represented by this
+ * object.
+ *
+ * @return The superclass of this class.
+ */
+public abstract ClassDoc
+superclass();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not the class represented by this object is
+ * a subclass of the specified class.
+ *
+ * @param cls The <code>ClassDoc</code> object of the class to test against.
+ *
+ * @return <code>true</code> if this class is a subclass of the specified
+ * class, <code>false</code> otherwise.
+ */
+public abstract boolean
+subclassOf(ClassDoc cls);
+
+/*************************************************************************/
+
+/**
+ * This method returns this list of interfaces implemented (or in the case
+ * of interfaces, extended) by this class. This list will only include
+ * interfaces directly implemented by this class, not those inherited by
+ * interfaced implemented in this class.
+ *
+ * @return The list of interfaces this class implements.
+ */
+public abstract ClassDoc[]
+interfaces();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of fields that are visible to the user in
+ * this class, or the list of all fields in this class.
+ *
+ * @param filtered if true, only return visible (included) fields;
+ * otherwise, return all fields.
+ *
+ * @return The list of visible fields in this class, or the list of
+ * all fields in this class.
+ */
+public abstract FieldDoc[]
+fields(boolean filtered);
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of fields that are visible to the user in
+ * this class. Does this depend on the -private -protected, etc flags
+ * passed to javadoc?
+ *
+ * @return The list of visible fields in this class.
+ */
+public abstract FieldDoc[]
+fields();
+
+/*************************************************************************/
+
+/**
+ * This method returns either the list of methods that are visible to
+ * the user in the class represented by this object, or a list of all
+ * methods, excluding constructor methods.
+ *
+ * @param filtered if true, only return visible (included) methods;
+ * otherwise, return all methods.
+ *
+ * @return The list of all methods in this class, or the list of
+ * visible methods in this class.
+ */
+public abstract MethodDoc[]
+methods(boolean filtered);
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of methods that are visible to the user in
+ * the class represented by this object, excluding constructor methods.
+ *
+ * @return The list of visible methods in this class.
+ */
+public abstract MethodDoc[]
+methods();
+
+/*************************************************************************/
+
+/**
+ * This method returns either the list of constructors that are
+ * visible to the user in the class represented by this object, or
+ * the list of all constructors.
+ *
+ * @param filtered if true, only return visible (included)
+ * constructors; otherwise, return all constructors.
+ *
+ * @return The list of all constructors in this class, or the list
+ * of visible constructors in this class.
+ */
+public abstract ConstructorDoc[]
+constructors(boolean filtered);
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of constructors that are visible to the user
+ * in the class represented by this object.
+ *
+ * @return The list visible constructors in this class.
+ */
+public abstract ConstructorDoc[]
+constructors();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of inner classes that are visible to
+ * the user within the class represented by this object.
+ *
+ * @return The list of visible inner classes for this object.
+ */
+public abstract ClassDoc[]
+innerClasses();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of all inner classes within the class
+ * represented by this object, or the list of visible inner classes
+ * in this class.
+ *
+ * @param filtered if true, only return visible (included) inner
+ * classes; otherwise, return all inner classes.
+ *
+ * @return The list of all inner classes for this object, or the list
+ * of visible inner classes.
+ */
+public abstract ClassDoc[]
+innerClasses(boolean filtered);
+
+/*************************************************************************/
+
+/**
+ * This method returns a <code>ClassDoc</code> for the named class. The
+ * following search order is used:
+ * <p>
+ * <ol>
+ * <li>Fully qualified class name.
+ * <li>Inner classes within this class.
+ * <li>In the current package.
+ * <li>In the imports for this class.
+ * </ol>
+ *
+ * @param name The name of the class to find.
+ *
+ * @return The requested class, or <code>null</code> if the requested
+ * class cannot be found.
+ */
+public abstract ClassDoc
+findClass(String name);
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of classes that are imported. This
+ * excludes any imports of complete packages.
+ *
+ * @return The list of imported classes.
+ */
+public abstract ClassDoc[]
+importedClasses();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of packages that are imported. This
+ * excludes any individual class imports.
+ *
+ * @return The list of imported packages.
+ */
+public abstract PackageDoc[]
+importedPackages();
+
+/*************************************************************************/
+
+/**
+ * This method returns the formal type parameters of this class.
+ * The returned array is empty if the class does not represent a
+ * parameterized type.
+ *
+ * @return The list of type parameters.
+ * @since 1.5
+ */
+TypeVariable[]
+typeParameters();
+
+} // interface ClassDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/ConstructorDoc.java b/libjava/classpath/tools/com/sun/javadoc/ConstructorDoc.java
new file mode 100644
index 000000000..88c8d3ddb
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/ConstructorDoc.java
@@ -0,0 +1,56 @@
+/* ConstructorDoc.java -- Document a Java class constructor
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface is used for documenting constructors.
+ */
+public interface ConstructorDoc extends ExecutableMemberDoc
+{
+
+/**
+ * This method returns the qualified name of the constructor. What is this
+ * really?
+ *
+ * @return The qualified name of the constructor.
+ */
+public abstract String
+qualifiedName();
+
+} // interface ConstructorDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/Doc.java b/libjava/classpath/tools/com/sun/javadoc/Doc.java
new file mode 100644
index 000000000..554720d69
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/Doc.java
@@ -0,0 +1,264 @@
+/* Doc.java -- Model of an item to document.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface is the super-interface of all items that can have
+ * Javadoc comments associated with them.
+ */
+public interface Doc extends java.io.Serializable, Comparable
+{
+
+/**
+ * This method returns the text of the comment for this item, with all
+ * tags stripped.
+ *
+ * @return The comment text for this item.
+ */
+public abstract String
+commentText();
+
+/*************************************************************************/
+
+/**
+ * This method returns an array of all the tags in this item.
+ *
+ * @return An array of tags for this item.
+ */
+public abstract Tag[]
+tags();
+
+/*************************************************************************/
+
+/**
+ * This method returns an array of all the tags of the specified type
+ * in this item.
+ *
+ * @param tagtype The name of the tag type to return.
+ *
+ * @return A list of all tags of the specified type.
+ */
+public abstract Tag[]
+tags(String tagtype);
+
+/*************************************************************************/
+
+/**
+ * This method returns an array of all tags of the "@see" type.
+ *
+ * @return An array of tags of the "@see" type
+ */
+public abstract SeeTag[]
+seeTags();
+
+/*************************************************************************/
+
+/**
+ * This method returns the comment text as an array of tags. This will
+ * include any inline tags, but no regular tags. Regular text is returned
+ * as a type of <code>Text</code>. Inline "@see" tags are returned as
+ * type <code>SeeTag</code>.
+ *
+ * @return The comment text as tags.
+ */
+public abstract Tag[]
+inlineTags();
+
+/*************************************************************************/
+
+/**
+ * This method returns the first sentence of the comment text as an array
+ * of tags. This will include any inline tags, but no regular tags.
+ * Regular text is returned as a type of <code>Text</code>. Inline "@see"
+ * tags are returned as type <code>SeeTag</code>.
+ *
+ * @return An array of tags representing the first sentence of the comment
+ * text.
+ */
+public abstract Tag[]
+firstSentenceTags();
+
+/*************************************************************************/
+
+/**
+ * This method returns the text of the comment in an unprocessed format.
+ * Any Javadoc tags will remain as written in the text.
+ *
+ * @return The unprocessed comment text.
+ */
+public abstract String
+getRawCommentText();
+
+/*************************************************************************/
+
+/**
+ * This method sets the unprocessed comment text for this item.
+ *
+ * @param rawtext The unprocessed comment text for this itme.
+ */
+public abstract void
+setRawCommentText(String rawtext);
+
+/*************************************************************************/
+
+/**
+ * This method returns the name of this item.
+ *
+ * @return The name of this item.
+ */
+public abstract String
+name();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is a field.
+ *
+ * @return <code>true</code> if this item is a field, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isField();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is a method.
+ *
+ * @return <code>true</code> if this item is a method, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isMethod();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is a constructor.
+ *
+ * @return <code>true</code> if this item is a constructor,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isConstructor();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is an interface.
+ *
+ * @return <code>true</code> if this item is an interface,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isInterface();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is an exception.
+ *
+ * @return <code>true</code> if this item is an exception,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isException();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is an error.
+ *
+ * @return <code>true</code> if this item is an error,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isError();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is a class. Interfaces
+ * do not count as classes.
+ *
+ * @return <code>true</code> if this item is a class,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isClass();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is an ordinary class. An
+ * ordinary class is a class that is not an exception or an error.
+ * Interfaces also do not count because they are not considered classes at
+ * all.
+ *
+ * @return <code>true</code> if this item is an ordinary class,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isOrdinaryClass();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this item is part of the active set,
+ * whatever that is.
+ *
+ * @return <code>true</code> if this item is part of the active set,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isIncluded();
+
+/*************************************************************************/
+
+/**
+ * This method returns the location of the item within the Java
+ * source code.
+ *
+ * @return an object describing the file, line and column where this
+ * item is defined.
+ */
+public abstract SourcePosition
+position();
+
+} // interface Doc
diff --git a/libjava/classpath/tools/com/sun/javadoc/DocErrorReporter.java b/libjava/classpath/tools/com/sun/javadoc/DocErrorReporter.java
new file mode 100644
index 000000000..2e801b848
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/DocErrorReporter.java
@@ -0,0 +1,76 @@
+/* DocErrorReporter.java -- Log errors/warnings during doc generation.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface provides a mechanism for a doclet to log messages
+ * during its run.
+ */
+public interface DocErrorReporter
+{
+
+/**
+ * This method prints the specified error message.
+ *
+ * @param err The error message to print.
+ */
+public abstract void
+printError(String err);
+
+/*************************************************************************/
+
+/**
+ * This method prints the specified warning message.
+ *
+ * @param warn The warning message to print.
+ */
+public abstract void
+printWarning(String warn);
+
+/*************************************************************************/
+
+/**
+ * This method prints the specifed message.
+ *
+ * @param msg The message to print.
+ */
+public abstract void
+printNotice(String notice);
+
+} // interface DocErrorReporter
diff --git a/libjava/classpath/tools/com/sun/javadoc/Doclet.java b/libjava/classpath/tools/com/sun/javadoc/Doclet.java
new file mode 100644
index 000000000..172387ebb
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/Doclet.java
@@ -0,0 +1,98 @@
+/* Doclet.java -- Doclet API
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This class documents the method that must be implemented by a doclet.
+ * It may be used as the superclass of a doclet, but this is not required.
+ * As long as the doclet implements the <code>start</code> method, all is ok.
+ */
+public abstract class Doclet
+{
+
+/**
+ * This is the entry point to a doclet. All doclets must implement this
+ * method.
+ *
+ * @param rd The <code>RootDoc</code> instance for this javadoc run.
+ *
+ * @return <code>true</code> on success, <code>false</code> on failure.
+ */
+public static boolean
+start(RootDoc root)
+{
+ return(false);
+}
+
+/*************************************************************************/
+
+/**
+ * This method returns the number of arguments to the option, including
+ * the option itself. This is not required of doclets.
+ *
+ * @param opt The option to check.
+ *
+ * @return The number of arguments to the option, or zero if the option is
+ * unknown, or a negative number if an error occurred.
+ */
+public static int
+optionLength(String opt)
+{
+ return(0);
+}
+
+/*************************************************************************/
+
+/**
+ * This method is called to verify that the options supplied by the caller
+ * are valid. This is not required of doclets.
+ *
+ * @param opts The list of options supplied by the user.
+ * @param logger A mechanism for this method to report errors to the user.
+ *
+ * @return <code>true</code> if the options are valid, <code>false</code>
+ * otherwise.
+ */
+public static boolean
+validOptions(String[][] opts, DocErrorReporter logger)
+{
+ return(true);
+}
+
+} // class Doclet
diff --git a/libjava/classpath/tools/com/sun/javadoc/ExecutableMemberDoc.java b/libjava/classpath/tools/com/sun/javadoc/ExecutableMemberDoc.java
new file mode 100644
index 000000000..ac0ca06f7
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/ExecutableMemberDoc.java
@@ -0,0 +1,137 @@
+/* ExecutableMemberDoc.java -- Document methods and constructors
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This is the super-interface for interfaces describing constructors and
+ * methods.
+ */
+public interface ExecutableMemberDoc extends MemberDoc
+{
+
+/**
+ * This method returns a list of all the execeptions that are declared
+ * to be thrown in this method or constructor.
+ *
+ * @return The list of exceptions for this method.
+ */
+public abstract ClassDoc[]
+thrownExceptions();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this method/constructor is native.
+ *
+ * @return <code>true</code> if the method is native, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isNative();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this method/constructor is
+ * synchronized.
+ *
+ * @return <code>true</code> if the method is synchronized,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isSynchronized();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of parameters for this method/constructor.
+ *
+ * @return The list of parameters for this method.
+ */
+public abstract Parameter[]
+parameters();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of "@throws" and "@exception" tags in this
+ * method/constructor.
+ *
+ * @return The list of exception doc tags.
+ */
+public abstract ThrowsTag[]
+throwsTags();
+
+/*************************************************************************/
+
+/**
+ * This method return the list of "@param" tags in this method/constructor.
+ *
+ * @return The list of parameter doc tags for this method.
+ */
+public abstract ParamTag[]
+paramTags();
+
+/*************************************************************************/
+
+/**
+ * This method returns the signature of this method in pseudo-code format,
+ * with fully qualified class references. For example, the method
+ * <code>read(String str, boolean bool)</code> would have the signature
+ * <code>(java.lang.String, boolean)</code> returned by this method.
+ *
+ * @return The signature for this method.
+ */
+public abstract String
+signature();
+
+/*************************************************************************/
+
+/**
+ * This method returns the signature of this method in pseudo-code format,
+ * with uqualified class references. For example, the method
+ * <code>read(String str, boolean bool)</code> would have the signature
+ * <code>(String, boolean)</code> returned by this method.
+ *
+ * @return The signature for this method.
+ */
+public abstract String
+flatSignature();
+
+} // interface ExecutableMemberDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/FieldDoc.java b/libjava/classpath/tools/com/sun/javadoc/FieldDoc.java
new file mode 100644
index 000000000..1fd0c7b83
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/FieldDoc.java
@@ -0,0 +1,112 @@
+/* FieldDoc.java -- Document a field
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This package is used for documenting fields.
+ */
+public interface FieldDoc extends MemberDoc
+{
+
+/**
+ * This method returns the type of this field.
+ *
+ * @return The type of this field.
+ */
+public abstract Type
+type();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not the field is transient.
+ *
+ * @return <code>true</code> if the field is transient, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isTransient();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not the field is volatile.
+ *
+ * @return <code>true</code> if the field is volatile, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isVolatile();
+
+/*************************************************************************/
+
+/**
+ * This method returns a list of all "@serialField" tags defined in this
+ * field.
+ *
+ * @return The list of "@serialField" tags for this field.
+ */
+public abstract SerialFieldTag[]
+serialFieldTags();
+
+/*************************************************************************/
+
+/**
+ * This method returns the value of this static field.
+ *
+ * @return The value of this static field.
+ */
+public abstract Object
+constantValue();
+
+
+/*************************************************************************/
+
+/**
+ * This method returns the value of this static field converted to a
+ * human-readable string.
+ *
+ * @return The value of this static field as a human-readable string.
+ */
+public abstract String
+constantValueExpression();
+
+
+
+} // interface FieldDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/MemberDoc.java b/libjava/classpath/tools/com/sun/javadoc/MemberDoc.java
new file mode 100644
index 000000000..9e755bbd6
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/MemberDoc.java
@@ -0,0 +1,59 @@
+/* MemberDoc.java -- Common ops for documenting fields, methods,
+ and constructors
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This is the common super-interface for documentation about fields,
+ * methods, and constructors.
+ */
+public interface MemberDoc extends ProgramElementDoc
+{
+
+/**
+ * This method tests whether the member in question was created implicitly
+ * by the compiler.
+ *
+ * @return <code>true</code> if this member was synthesized by the compiler,
+ * </code>false</code> otherwise.
+ */
+public abstract boolean
+isSynthetic();
+
+} // interface MemberDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/MethodDoc.java b/libjava/classpath/tools/com/sun/javadoc/MethodDoc.java
new file mode 100644
index 000000000..87129ef44
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/MethodDoc.java
@@ -0,0 +1,79 @@
+/* MethodDoc.java -- Document a method
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface is used for documenting ordinary (ie, non-constructor)
+ * methods.
+ */
+public interface MethodDoc extends ExecutableMemberDoc
+{
+
+/**
+ * This method tests whether or not the method to be documented is abstract.
+ *
+ * @return <code>true</code> if the method is abstract, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isAbstract();
+
+/*************************************************************************/
+
+/**
+ * This method returns the return type of the method to be documented.
+ *
+ * @return The return type of the method to be documented.
+ */
+public abstract Type
+returnType();
+
+/*************************************************************************/
+
+/**
+ * This method returns the class containing the method that this method is
+ * overriding.
+ *
+ * @return The class containing the method that this method is overriding,
+ * or <code>null</code> if this class is not overriding a method.
+ */
+public abstract ClassDoc
+overriddenClass();
+
+} // interface MethodDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/PackageDoc.java b/libjava/classpath/tools/com/sun/javadoc/PackageDoc.java
new file mode 100644
index 000000000..4518b4eba
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/PackageDoc.java
@@ -0,0 +1,108 @@
+/* PackageDoc.java -- Document a package
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+public interface PackageDoc extends Doc
+{
+
+/**
+ * This method returns a list of all the classes and interfaces in
+ * this package. This list will included exceptions and errors.
+ *
+ * @return The list of classes and interfaces for this package.
+ */
+public abstract ClassDoc[]
+allClasses();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of ordinary classes in this package. This
+ * list will not include any interface, exceptions or errors.
+ *
+ * @return The list of ordinary classes in this package.
+ */
+public abstract ClassDoc[]
+ordinaryClasses();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of exceptions in this package.
+ *
+ * @return The list of exceptions in this package.
+ */
+public abstract ClassDoc[]
+exceptions();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of errors in this package.
+ *
+ * @return The list of errors in this package.
+ */
+public abstract ClassDoc[]
+errors();
+
+/*************************************************************************/
+
+/**
+ * This method returns the list of interfaces in this package.
+ *
+ * @return The list of interfaces in this package.
+ */
+public abstract ClassDoc[]
+interfaces();
+
+/*************************************************************************/
+
+/**
+ * This method returns a <code>ClassDoc</code> instance for the specified
+ * class.
+ *
+ * @param name The name of the class to return.
+ *
+ * @return The requested <code>ClassDoc</code> or <code>null</code> if
+ * this class not part of this javadoc run.
+ */
+public abstract ClassDoc
+findClass(String cls);
+
+} // interface PackageDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/ParamTag.java b/libjava/classpath/tools/com/sun/javadoc/ParamTag.java
new file mode 100644
index 000000000..9c060e901
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/ParamTag.java
@@ -0,0 +1,65 @@
+/* ParamTag.java -- Documentation tag for method parameters
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface represents an "@param" tag.
+ */
+public interface ParamTag extends Tag
+{
+
+/**
+ * This method returns the comment text for the parameter.
+ *
+ * @return The comment text for the parameter.
+ */
+public abstract String
+parameterComment();
+
+/*************************************************************************/
+
+/**
+ * This method returns the name of the parameter.
+ *
+ * @return The name of the parameter.
+ */
+public abstract String
+parameterName();
+
+} // interface ParamTag
diff --git a/libjava/classpath/tools/com/sun/javadoc/Parameter.java b/libjava/classpath/tools/com/sun/javadoc/Parameter.java
new file mode 100644
index 000000000..300a3355a
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/Parameter.java
@@ -0,0 +1,87 @@
+/* Parameter.java -- Information about parameters to methods.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface models a parameter to a method.
+ */
+public interface Parameter extends java.io.Serializable
+{
+
+/**
+ * This method returns the type of the parameter.
+ *
+ * @return The parameter type.
+ */
+public abstract Type
+type();
+
+/*************************************************************************/
+
+/**
+ * This method returns the name of the parameter.
+ *
+ * @return The parameter name.
+ */
+public abstract String
+name();
+
+/*************************************************************************/
+
+/**
+ * This method returns the name of the type of the parameter as a
+ * <code>String</code>.
+ *
+ * @return The name of the type of this parameter.
+ */
+public abstract String
+typeName();
+
+/*************************************************************************/
+
+/**
+ * This method returns this parameter as a <code>String</code> that
+ * contains both the type name and parameter name.
+ *
+ * @return This parameter as a <code>String</code>.
+ */
+public abstract String
+toString();
+
+} // interaface Parameter
diff --git a/libjava/classpath/tools/com/sun/javadoc/ProgramElementDoc.java b/libjava/classpath/tools/com/sun/javadoc/ProgramElementDoc.java
new file mode 100644
index 000000000..061e327e1
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/ProgramElementDoc.java
@@ -0,0 +1,169 @@
+/* ProgramElementDoc.java -- Common ops for all program elements.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This is the comment super-interface of all items that are "program
+ * elements". This includes classes, interfaces, fields, constructors,
+ * and methods.
+ */
+public interface ProgramElementDoc extends Doc
+{
+
+/**
+ * This method returns the class which contains this element. If this
+ * is a class that is not an inner class, <code>null</code> will be
+ * returned.
+ *
+ * @returned The class element that contains this item, or <code>null</code>
+ * if this item is a class that is not an inner class.
+ */
+public abstract ClassDoc
+containingClass();
+
+/*************************************************************************/
+
+/**
+ * This method returns the package which contains this element. If this
+ * element is in the default generic package, then the name of the
+ * package element returned will be "".
+ *
+ * @return The package element that contains this item.
+ */
+public abstract PackageDoc
+containingPackage();
+
+/*************************************************************************/
+
+/**
+ * This method returns the fully qualified name of this element.
+ *
+ * @return The fully qualified name of this element.
+ */
+public abstract String
+qualifiedName();
+
+/*************************************************************************/
+
+/**
+ * This method returns the modifier specificier number, which is what?
+ *
+ * @return The modifier for this element.
+ */
+public abstract int
+modifierSpecifier();
+
+/*************************************************************************/
+
+/**
+ * This method returns a string with the element modifiers. For example,
+ * the modifiers of a method declaration might be "protected abstract".
+ *
+ * @return The modifier string.
+ */
+public abstract String
+modifiers();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this element is public.
+ *
+ * @return <code>true</code> if this element is public, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isPublic();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this element is protected.
+ *
+ * @return <code>true</code> if this element is protected, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isProtected();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this element is private.
+ *
+ * @return <code>true</code> if this element is private, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isPrivate();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this element is package private.
+ *
+ * @return <code>true</code> if this element is package private,
+ * <code>false</code> otherwise.
+ */
+public abstract boolean
+isPackagePrivate();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this element is static.
+ *
+ * @return <code>true</code> if this element is static, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isStatic();
+
+/*************************************************************************/
+
+/**
+ * This method tests whether or not this element is final.
+ *
+ * @return <code>true</code> if this element is final, <code>false</code>
+ * otherwise.
+ */
+public abstract boolean
+isFinal();
+
+} // interface ProgramElementDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/RootDoc.java b/libjava/classpath/tools/com/sun/javadoc/RootDoc.java
new file mode 100644
index 000000000..18be71dde
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/RootDoc.java
@@ -0,0 +1,111 @@
+/* RootDoc.java -- Information about a javadoc run.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package com.sun.javadoc;
+
+/**
+ * This interface is the root of the javadoc application. All the properties and
+ * arguments are attached to the class that will implements this interface. You
+ * can retrieve all the options of the tool with this interface.
+ */
+public interface RootDoc extends Doc, DocErrorReporter
+{
+
+ /**
+ * This method returns the command line element used to invoke this instance
+ * of javadoc.
+ *
+ * @return The command line arguments for this run.
+ */
+ public abstract String[][] options();
+
+ /** ********************************************************************** */
+
+ /**
+ * This method returns the list of packages that were specified on the command
+ * line.
+ *
+ * @return The packages specified on the command line.
+ */
+ public abstract PackageDoc[] specifiedPackages();
+
+ /** ********************************************************************** */
+
+ /**
+ * This method returns the list of classes that were specified on the command
+ * line.
+ *
+ * @return The classes specified on the command line.
+ */
+ public abstract ClassDoc[] specifiedClasses();
+
+ /** ********************************************************************** */
+
+ /**
+ * This method returns the list of classes and interfaces to be documented.
+ *
+ * @return The list of classes and interfaces to be documented.
+ */
+ public abstract ClassDoc[] classes();
+
+ /** ********************************************************************** */
+
+ /**
+ * This method returns a <code>ClassDoc</code> instance for the name class
+ * or interface.
+ *
+ * @param name
+ * The class or interface to look up.
+ * @return The requested <code>ClassDoc</code>, or null if the specified
+ * class is not part of this javadoc run.
+ */
+ public abstract ClassDoc classNamed(String name);
+
+ /** ********************************************************************** */
+
+ /**
+ * This method returns a <code>PackageDoc</code> instance for the named
+ * package.
+ *
+ * @param name
+ * The package to look up.
+ * @return The requested <code>PackageDoc</code>, or null if the specified
+ * package is not part of this javadoc run.
+ */
+ public abstract PackageDoc packageNamed(String name);
+
+} // interface RootDoc
diff --git a/libjava/classpath/tools/com/sun/javadoc/SeeTag.java b/libjava/classpath/tools/com/sun/javadoc/SeeTag.java
new file mode 100644
index 000000000..7e5b305ae
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/SeeTag.java
@@ -0,0 +1,108 @@
+/* SeeTag.java -- Information about "@see" tags.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface models an "@see" tag.
+ */
+public interface SeeTag extends Tag
+{
+
+/**
+ * This method returns the label for this tag. What is this????
+ *
+ * @return The label for this tag.
+ */
+public abstract String
+label();
+
+/*************************************************************************/
+
+/**
+ * This method returns the package of the referenced item.
+ *
+ * @return The package of the referenced item, or <code>null</code> if no
+ * package is found.
+ */
+public abstract PackageDoc
+referencedPackage();
+
+/*************************************************************************/
+
+/**
+ * This method returns the name of the class referenced in the tag.
+ *
+ * @return The name of the class referenced in the tag.
+ */
+public abstract String
+referencedClassName();
+
+/*************************************************************************/
+
+/**
+ * This method returns a <code>ClassDoc</code> instance for the class
+ * referenced in the tag.
+ *
+ * @return A <code>ClassDoc</code> for the class referenced in the tag.
+ */
+public abstract ClassDoc
+referencedClass();
+
+/*************************************************************************/
+
+/**
+ * This method returns the name of the member referenced in the tag.
+ *
+ * @return The name of the member referenced in the tag.
+ */
+public abstract String
+referencedMemberName();
+
+/*************************************************************************/
+
+/**
+ * This method returns a <code>MemberDoc</code> instance for the member
+ * referenced in the tag.
+ *
+ * @return A <code>MemberDoc</code> for the member referenced in the tag.
+ */
+public abstract MemberDoc
+referencedMember();
+
+} // interface SeeTag
diff --git a/libjava/classpath/tools/com/sun/javadoc/SerialFieldTag.java b/libjava/classpath/tools/com/sun/javadoc/SerialFieldTag.java
new file mode 100644
index 000000000..ef692834c
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/SerialFieldTag.java
@@ -0,0 +1,101 @@
+/* SerialFieldTag.java -- Information about the "@serialField" tag.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface models the "@serialField" tag.
+ */
+public interface SerialFieldTag extends Tag, Comparable
+{
+
+/**
+ * This method returns the name of the field.
+ *
+ * @return The name of the field.
+ */
+public abstract String
+fieldName();
+
+/*************************************************************************/
+
+/**
+ * This method returns the type name of the field.
+ *
+ * @return The type name of the field.
+ */
+public abstract String
+fieldType();
+
+/*************************************************************************/
+
+/**
+ * This method returns a <code>ClassDoc</code> instance for the type of
+ * the field. What about primitive types???
+ *
+ * @return A <code>ClassDoc</code> for the field type.
+ */
+public abstract ClassDoc
+fieldTypeDoc();
+
+/*************************************************************************/
+
+/**
+ * This method returns the description of the field.
+ *
+ * @return The description of the field.
+ */
+public abstract String
+description();
+
+/*************************************************************************/
+
+/**
+ * This method compares this object with the specified object in order to
+ * determine proper ordering.
+ *
+ * @param obj The object to compare against.
+ *
+ * @return A negative number if this object is less than the specified
+ * object, zero if the objects are equal, or a positive number if this object
+ * is greater than the specified object.
+ */
+public abstract int
+compareTo(Object obj);
+
+} // interface SerialFieldTag
diff --git a/libjava/classpath/tools/com/sun/javadoc/SourcePosition.java b/libjava/classpath/tools/com/sun/javadoc/SourcePosition.java
new file mode 100644
index 000000000..fff25595f
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/SourcePosition.java
@@ -0,0 +1,68 @@
+/* SourcePosition.java -- Model of a location in a source file.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+import java.io.File;
+
+/**
+ * Represents a location in a source file. This is used by {@link
+ * Doc} to specify at which location an item is defined.
+ */
+public interface SourcePosition
+{
+ /**
+ * Return a File object pointing to the source file.
+ */
+ public File file();
+
+ /**
+ * Return the 1-based line number within the source file.
+ */
+ public int line();
+
+ /**
+ * Return the 1-based column number within the source file.
+ */
+ public int column();
+
+ /**
+ * Return a string in the format "file.toString():line"
+ */
+ public String toString();
+}
diff --git a/libjava/classpath/tools/com/sun/javadoc/Tag.java b/libjava/classpath/tools/com/sun/javadoc/Tag.java
new file mode 100644
index 000000000..88745cb98
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/Tag.java
@@ -0,0 +1,106 @@
+/* Tag.java -- Common operations on Javadoc tags.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This is the super-interface for all Javadoc tags.
+ */
+public interface Tag extends java.io.Serializable
+{
+/**
+ * This method returns the name of the tag.
+ *
+ * @return The name of the tag.
+ */
+public abstract String
+name();
+
+/*************************************************************************/
+
+/**
+ * This method returns the kind of tag. ????
+ *
+ * @return The kind of the tag.
+ */
+public abstract String
+kind();
+
+/*************************************************************************/
+
+/**
+ * This method returns the text for this tag.
+ *
+ * @return The text for this tag.
+ */
+public abstract String
+text();
+
+/*************************************************************************/
+
+/**
+ * This method returns the tag as a <code>String</code>. What kind of
+ * string?
+ *
+ * @return This tag as a <code>String</code>.
+ */
+public abstract String
+toString();
+
+/*************************************************************************/
+
+/**
+ * This method returns the inline tags for this comment.
+ *
+ * @return The inline tags for this comment.
+ */
+public abstract Tag[]
+inlineTags();
+
+/*************************************************************************/
+
+/**
+ * This method returns the first sentence of the doc comment as an array
+ * of <code>Tag</code>'s.
+ *
+ * @return The first sentence of the comment as tags.
+ */
+public abstract Tag[]
+firstSentenceTags();
+
+} // interface Tag
diff --git a/libjava/classpath/tools/com/sun/javadoc/ThrowsTag.java b/libjava/classpath/tools/com/sun/javadoc/ThrowsTag.java
new file mode 100644
index 000000000..0d5a98e85
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/ThrowsTag.java
@@ -0,0 +1,75 @@
+/* ThrowsTag.java -- Information about "@throws" and "@exception" tags.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This interface models an "@exception" or "@throws" tag.
+ */
+public interface ThrowsTag extends Tag
+{
+
+/**
+ * This method returns the name of the exception.
+ *
+ * @return The name of the exception.
+ */
+public abstract String
+exceptionName();
+
+/*************************************************************************/
+
+/**
+ * This method returns the comment text of the exception.
+ *
+ * @return The comment text of the exception.
+ */
+public abstract String
+exceptionComment();
+
+/*************************************************************************/
+
+/**
+ * This method returns the exception class as a <code>ClassDoc</code>.
+ *
+ * @return The exception class as a <code>ClassDoc</code>.
+ */
+public abstract ClassDoc
+exception();
+
+} // interface ThrowsTag
diff --git a/libjava/classpath/tools/com/sun/javadoc/Type.java b/libjava/classpath/tools/com/sun/javadoc/Type.java
new file mode 100644
index 000000000..0aabe0e78
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/Type.java
@@ -0,0 +1,119 @@
+/* Type.java -- Documentation information about Java types.
+ Copyright (C) 1999 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This class is used for holding information about Java types needed for
+ * documentation.
+ */
+public interface Type extends java.io.Serializable
+{
+
+/**
+ * This method returns the unqualified name of the type, excluding any array
+ * dimension information or brackets.
+ *
+ * @return The unqualified type name, sans array information or brackets.
+ */
+public abstract String
+typeName();
+
+/*************************************************************************/
+
+/**
+ * This method returns the fully qualified name of the type, excluding any
+ * array dimension information or brackets.
+ *
+ * @return The fully qualified type name, sans array information or brackets.
+ */
+public abstract String
+qualifiedTypeName();
+
+/*************************************************************************/
+
+/**
+ * This method returns the array dimensions as brackets.
+ *
+ * @param The array dimensions.
+ */
+public abstract String
+dimension();
+
+/*************************************************************************/
+
+/**
+ * This method returns the unqualfied name of the type, and includes array
+ * dimension information.
+ *
+ * @return The unqualified name of the type, including array dimension info.
+ */
+public abstract String
+toString();
+
+/*************************************************************************/
+
+/**
+ * This method returns this type as a <code>ClassDoc</object>. This is not
+ * a valid operation for primitive types.
+ *
+ * @return A <code>ClassDoc</code> for this type, or <code>null</code> if
+ * this is a primitive type.
+ */
+public abstract ClassDoc
+asClassDoc();
+
+/**
+ * This method returns whether this type represents one of the
+ * built-in Java primitive types.
+ */
+public abstract boolean
+isPrimitive();
+
+/**
+ * Returns this type as a <code>TypeVariable</code>, if it is an
+ * instance of the <code>TypeVariable</code> class. Otherwise,
+ * it returns null.
+ *
+ * @return this cast to a <code>TypeVariable</code> instance, or null
+ * if this is not a type variable.
+ */
+TypeVariable
+asTypeVariable();
+
+} // interface Type
diff --git a/libjava/classpath/tools/com/sun/javadoc/TypeVariable.java b/libjava/classpath/tools/com/sun/javadoc/TypeVariable.java
new file mode 100644
index 000000000..94da50507
--- /dev/null
+++ b/libjava/classpath/tools/com/sun/javadoc/TypeVariable.java
@@ -0,0 +1,73 @@
+/* TypeVariable.java -- Document a Java type variable.
+ Copyright (C) 2005 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package com.sun.javadoc;
+
+/**
+ * This class represents a type variable, which is used to parameterize
+ * the types used in a method or class. For example,
+ * <code>List&lt;E&gt;</code> has the type variable, <code>E</code>. Type
+ * variables may have explicit bounds, such as <code>&lt;T extends
+ * Book&gt;</code>, which specifies that the type is a sub-class of
+ * <code>Book</code>.
+ *
+ * @since 1.5
+ * @author Andrew John Hughes (gnu_andrew@member.fsf.org)
+ */
+public interface TypeVariable
+ extends Type
+{
+
+ /**
+ * Returns the bounds of this type variable. These are the types
+ * represented in the <code>extends</code> clause.
+ *
+ * @return an array of types which specify the bounds of this variable.
+ * The array is empty if there are no explicit bounds.
+ */
+ Type[] bounds();
+
+ /**
+ * Returns the class, interface, method or constructor in which this
+ * type variable was declared.
+ *
+ * @return the owning program element for this type variable.
+ */
+ ProgramElementDoc owner();
+
+}