You are viewing a plain text version of this content. The canonical link for it is here.
Posted to kato-commits@incubator.apache.org by sp...@apache.org on 2009/07/19 09:02:43 UTC
svn commit: r795498 - in
/incubator/kato/branches/experimental/maven_restructure/org.apache.kato: ./
kato.anttasks/ kato.anttasks/src/main/java/org/apache/kato/anttasks/xmlgen/
kato.api/ kato.api/src/ant/
kato.api/src/main/java/javax/tools/diagnostics/...
Author: spoole
Date: Sun Jul 19 09:02:41 2009
New Revision: 795498
URL: http://svn.apache.org/viewvc?rev=795498&view=rev
Log:
New ant task to spit out javadoc as xml + new docs module to consume xmljavadoc and produce spec.
Added:
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.classpath
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.project
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.eclipse.jdt.core.prefs
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.maven.ide.eclipse.prefs
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/pom.xml
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/ant/
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/ant/buildjavadoc.xml (with props)
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/API.xml
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/Introduction.xml
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/sections/
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/fo.xsl
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/spec.xml
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagecontents.xslt
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagelist.xslt
Removed:
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/package-info.java
Modified:
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/pom.xml
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/src/main/java/org/apache/kato/anttasks/xmlgen/XMLWriter.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/pom.xml
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/ant/spec.xml
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClass.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClassLoader.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaField.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaHeap.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaMember.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaRuntime.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMInitArgs.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMOption.java
incubator/kato/branches/experimental/maven_restructure/org.apache.kato/pom.xml
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/pom.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/pom.xml?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/pom.xml (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/pom.xml Sun Jul 19 09:02:41 2009
@@ -17,19 +17,7 @@
<artifactId>ant</artifactId>
<version>1.7.1</version>
</dependency>
- <!--
- <dependency>
- <groupId>ant-contrib</groupId>
- <artifactId>ant-contrib</artifactId>
- <version>1.0b2</version>
- </dependency>
-
- <dependency>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-javadoc-plugin</artifactId>
- <version>2.5</version>
- </dependency>
- -->
+
<dependency>
<groupId>com.sun</groupId>
<artifactId>tools</artifactId>
@@ -37,20 +25,8 @@
<scope>system</scope>
<systemPath>${java.home}/../lib/tools.jar</systemPath>
</dependency>
- <!--
- <dependency>
- <groupId>com.lowagie</groupId>
- <artifactId>itext</artifactId>
- <version>2.1.5</version>
- </dependency>
<dependency>
- <groupId>org.htmlparser</groupId>
- <artifactId>htmlparser</artifactId>
- <version>1.6</version>
- </dependency>
- -->
- <dependency>
<groupId>net.sourceforge.nekohtml</groupId>
<artifactId>nekohtml</artifactId>
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/src/main/java/org/apache/kato/anttasks/xmlgen/XMLWriter.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/src/main/java/org/apache/kato/anttasks/xmlgen/XMLWriter.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/src/main/java/org/apache/kato/anttasks/xmlgen/XMLWriter.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.anttasks/src/main/java/org/apache/kato/anttasks/xmlgen/XMLWriter.java Sun Jul 19 09:02:41 2009
@@ -19,8 +19,10 @@
import com.sun.javadoc.FieldDoc;
import com.sun.javadoc.MethodDoc;
import com.sun.javadoc.PackageDoc;
+import com.sun.javadoc.ParamTag;
+import com.sun.javadoc.Parameter;
import com.sun.javadoc.Tag;
-import com.sun.tools.doclets.internal.toolkit.util.TextTag;
+import com.sun.javadoc.Type;
public class XMLWriter {
@@ -46,8 +48,8 @@
out=new PrintWriter(model);
-
- write("<javadoc>");
+ //write("<javadoc>");
+ write("<javadoc xmlns:html=\"http://www.w3.org/1999/xhtml\" xmlns:db=\"http://docbook.org/ns/docbook\" xmlns=\"http://apache.org/javadoc\">");
@@ -55,7 +57,11 @@
}
public void writeClass(ClassDoc c) throws IOException {
- write("<class type=\"class\" name=\""+c.name()+"\">");
+ write("<class name=\""+c.name()+"\">");
+
+ Tag[] tags=c.firstSentenceTags();
+ writeSummary(tags);
+
writeComment(c.commentText());
for(FieldDoc f:c.fields()) {
writeField(f);
@@ -77,11 +83,64 @@
}
private void writeMethod(MethodDoc m) throws IOException {
write("<method name=\""+m.name()+"\" signature=\""+m.signature()+"\" >");
+
+ Parameter[] parameters=m.parameters();
+ write(parameters);
+
+ ParamTag[] ptags=m.paramTags();
+ write(ptags);
+
+ Type t=m.returnType();
+ writeType("returntype",t);
+ write("<modifiers>"+m.modifiers()+"</modifiers>");
+
writeComment(m.commentText());
write("</method>");
}
+ private void write(ParamTag[] parameters) {
+ if(parameters==null || parameters.length==0) return;
+ write("<paramdescs>");
+ for(ParamTag p:parameters) {
+ write(p);
+ }
+ write("</paramdescs>");
+
+ }
+ private void write(ParamTag p) {
+ String name=p.parameterName();
+
+ String comment=p.parameterComment();
+ if(comment==null || comment.trim().equals("")) return;
+
+ write("<paramdesc name=\""+name+"\">");
+ write(p.parameterComment());
+ write("</paramdesc>");
+ }
+ private void write(Parameter[] parameters) {
+ if(parameters==null || parameters.length==0) return;
+ write("<parameters>");
+ for(Parameter p:parameters) {
+ write(p);
+ }
+ write("</parameters>");
+ }
+ private void write(Parameter p) {
+ write("<parameter type=\""+p.typeName()+"\" name=\""+p.name() + "\">");
+ Type t=p.type();
+ writeType("type",t);
+ write("</parameter>");
+
+ }
+ private void writeType(String tag,Type t) {
+ write("<"+tag+">");
+ write("<name>"+t.typeName()+"</name>");
+ write("<simple>"+t.simpleTypeName()+"</simple>");
+ write("<qualified>"+t.qualifiedTypeName()+"</qualified>");
+
+ write("</"+tag+">");
+ }
private void writeConstructor(ConstructorDoc r) throws IOException {
write("<constructor signature=\""+r.signature()+"\" >");
writeComment(r.commentText());
@@ -138,6 +197,18 @@
break;
case Node.ELEMENT_NODE :
String name=n.getNodeName();
+ if(name.equals("BR")) name="html:br";
+ if(name.equals("H1")) name="db:sect2";
+ if(name.equals("H2")) name="db:sect3";
+ if(name.equals("H3")) name="db:sect4";
+ if(name.equals("H4")) name="db:sect5";
+ if(name.equals("P")) name="db:para";
+ if(name.equals("UL")) name="db:itemizedlist";
+ if(name.equals("OL")) name="db:orderedlist";
+ if(name.equals("LI")) name="db:listitem";
+ if(name.equals("A")) name="db:link";
+ if(name.equals("PRE")) name="db:programlisting";
+
write("<"+name+">");
if(n.hasChildNodes()) {
NodeList kids=n.getChildNodes();
@@ -157,33 +228,22 @@
}
public void writeInterface(ClassDoc c) throws IOException {
- write("<class type=\"interface\" name=\""+c.name()+"\">");
+ write("<interface name=\""+c.name()+"\">");
+ Tag[] tags=c.firstSentenceTags();
+ writeSummary(tags);
writeComment(c.commentText());
for(MethodDoc m:c.methods()) {
writeMethod(m);
}
- write("</class>");
+ write("</interface>");
}
public void addPackageContents(PackageDoc p) throws IOException {
write("<package name=\""+p.name()+"\">");
Tag[] tags=p.firstSentenceTags();
- if(tags!=null && tags.length>0) {
- StringBuilder sb=new StringBuilder();
-
- for(Tag t:tags) {
- String kind=t.kind();
- if(kind.equals("Text")) {
- sb.append(t.text()+" ");
- }
- else {
- System.out.println("tag="+t.getClass());
- }
- }
-
- writeSummary(sb.toString());
- }
+
+ writeSummary(tags);
writeComment(p.commentText());
@@ -198,6 +258,23 @@
write("</package>");
}
+ private void writeSummary(Tag[] tags) throws IOException {
+ if(tags!=null && tags.length>0) {
+ StringBuilder sb=new StringBuilder();
+
+ for(Tag t:tags) {
+ String kind=t.kind();
+ if(kind.equals("Text")) {
+ sb.append(t.text()+" ");
+ }
+ else {
+ System.out.println("tag="+t.getClass());
+ }
+ }
+
+ writeSummary(sb.toString());
+ }
+ }
private void writeSummary(String text) throws IOException {
writeText("summary",text);
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/pom.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/pom.xml?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/pom.xml (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/pom.xml Sun Jul 19 09:02:41 2009
@@ -15,41 +15,48 @@
<version>3.8.1</version>
<scope>test</scope>
</dependency>
+ <dependency>
+ <groupId>org.apache.kato</groupId>
+ <artifactId>kato.anttasks</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ </dependency>
+
</dependencies>
<version>0.0.1-SNAPSHOT</version>
<name>JSR 326 API</name>
<description>Java classes that define the JSR 326 API</description>
-
-<reporting>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-javadoc-plugin</artifactId>
- <configuration>
- <doclet>org.umlgraph.doclet.UmlGraphDoc</doclet>
- <docletArtifact>
- <groupId>org.umlgraph</groupId>
- <artifactId>doclet</artifactId>
- <version>5.1</version>
- </docletArtifact>
- <additionalparam>-overview ${basedir}/src/javadoc/overview.html</additionalparam>
- </configuration>
- </plugin>
- </plugins>
- </reporting>
<build>
<plugins>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <executions>
+ <execution>
+ <phase>compile</phase>
+ <goals>
+ <goal>javadoc</goal>
+ </goals>
+ </execution>
+ </executions>
+
+ </plugin>
+
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
+ <version>1.3</version>
<executions>
<execution>
<id>compile</id>
<phase>compile</phase>
<configuration>
<tasks>
- <ant antfile="spec.xml" dir="src/ant" target="pdf">
- <property name="kato.aurigadoclet.jar" value="${kato.aurigadoclet.jar}"/>
+ <ant antfile="spec.xml" dir="src/ant" target="create-spec">
+ <property name="src" location="src"/>
+ <property name="build" value="${project.build.directory}/spec"/>
+ <property name="path" refid="maven.runtime.classpath"/>
</ant>
</tasks>
</configuration>
@@ -58,6 +65,45 @@
</goals>
</execution>
</executions>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ant</groupId>
+ <artifactId>ant-trax</artifactId>
+ <version>1.7.1</version>
+ </dependency>
+
+
+ </dependencies>
+
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.doxia</groupId>
+ <artifactId>doxia-maven-plugin</artifactId>
+ <version>1.1</version>
+ <executions>
+ <execution>
+ <phase>pre-site</phase>
+ <goals>
+ <goal>render-books</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <books>
+ <book>
+ <directory>target/spec</directory>
+ <descriptor>target/spec/spec.xml</descriptor>
+ <formats>
+
+ <format>
+ <id>pdf</id>
+ </format>
+
+ </formats>
+ </book>
+ </books>
+ </configuration>
+
</plugin>
</plugins>
</build>
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/ant/spec.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/ant/spec.xml?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/ant/spec.xml (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/ant/spec.xml Sun Jul 19 09:02:41 2009
@@ -1,46 +1,41 @@
<project>
- <property name="src" location="../main/java"/>
- <property name="out" location="../../target/site/spec/spec.pdf"/>
- <property name="data" location="../javadoc"/>
- <property name="cover" location="${data}/overview.html"/>
- <property name="logo" location="${data}/logo.jpg"/>
- <property name="target" location="../../target/site/spec"/>
+ <property name="javasrc" location="${src}/main/java"/>
+ <property name="stylesrc" location="${src}/xslt"/>
+ <property name="book.src" location="${src}/books/spec"/>
+ <property name="book.dir" location="${build}"/>
+ <property name="javadoc.xml" location="${build}/xml/javadoc.xml"/>
- <target name="pdf">
+ <property name="packagelist.xhtml" location="${build}/xhtml/packagelist.xhtml"/>
+ <taskdef resource="org/apache/kato/anttasks/anttasks.properties">
+ <classpath path="${path}"/>
+ </taskdef>
- <available property="auriga.doclet.available" type="file" file="${kato.aurigadoclet.jar}"/>
- <antcall target="create-spec"/>
- <antcall target="no-spec"/>
- </target>
- <target name="create-spec" if="auriga.doclet.available">
- <mkdir dir="${target}"/>
- <copy todir="${target}" file="${logo}"/>
-
- <echo>Building pdf using ${src}</echo>
-
- <javadoc sourcepath="${src}" additionalparam="-format pdf -out ${out} -coverfile ${cover}">
- <doclet name="com.aurigalogic.doclet.core.Doclet"
- path="${kato.aurigadoclet.jar}">
- </doclet>
- <fileset dir="${src}"/>
-
- </javadoc>
-
- </target>
- <target name="no-spec" unless="auriga.doclet.available">
+ <target name="create-spec" >
+
+ <!-- create a place to build the book -->
+ <mkdir dir="${book.dir}"/>
+
+ <!-- copy in the static parts -->
+
+ <copy todir="${book.dir}" >
+ <fileset dir="${book.src}" />
+ </copy>
+
+
+ <!-- create xml definition of the javadoc -->
+
+ <xmljavadoc sourcepath="${src}" output="${javadoc.xml}" docletpath="${path}">
+ <fileset dir="${javasrc}"/>
+ </xmljavadoc>
+
+ <!-- create the package list book page -->
+
+ <xslt style="${stylesrc}/packagelist.xslt"
+ in="${javadoc.xml}"
+ out="${packagelist.xhtml}" >
+ </xslt>
- <dirname property="doc.dir" file="${kato.aurigadoclet.jar}"/>
- <available property="auriga.doclet.exists" value="exists" file="${doc.dir}"/>
- <property name="auriga.doclet.exists" value="does not exist"/>
-
- <echo>
- Unable to create pdf specification document
- Set maven property kato.aurigadoclet.jar in local settings to point to jar containing
- required doclet. (Visit http://aurigadoclet.sourceforge.net/) for more information
- Current value of property is [${kato.aurigadoclet.jar}]
- The containing directory ${doc.dir} ${auriga.doclet.exists}
- </echo>
</target>
</project>
\ No newline at end of file
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClass.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClass.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClass.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClass.java Sun Jul 19 09:02:41 2009
@@ -23,11 +23,14 @@
/**
* Represents a Java class.
*
+ * A Java Class can have fields and methods. It is a shallow model of a loaded <a href="http://java.sun.com/docs/books/jvms/second_edition/html/ClassFile.doc.html">class file</a>
+ * or special types such as array types or primitive types in the Java Virtual Machine.
+ *
*/
public interface JavaClass {
/**
- * Fetch the java.lang.Class object associated with this class.
+ * Fetch the {@link java.lang.Class} object associated with this class.
* <p>
* In some implementations this may be null if no object has been
* created to represent this class, or if the class is synthetic.
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClassLoader.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClassLoader.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClassLoader.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaClassLoader.java Sun Jul 19 09:02:41 2009
@@ -21,50 +21,80 @@
/**
- * Represents an internal ClassLoader structure within a Java VM instance.
- * For most ClassLoaders there is a corresponding java.lang.ClassLoader
+ * <p>
+ * Represents an internal ClassLoader structure within a Java Virtual Machine instance.
+ * For most ClassLoaders there is a corresponding {@link java.lang.ClassLoader}
* instance within with JavaRuntime. For primordial class loaders such as
* the bootstrap class loader, there may or may not be a corresponding
- * java.lang.ClassLoader instance.
- *
+ * {@link java.lang.ClassLoader} instance.
+ * </p>
+ * <p>
* Since Java does not define any strict inheritance structure between
* class loaders, there are no APIs for inspecting 'child' or 'parent'
* class loaders. This information may be inferred by inspecting the
- * corresponding java.lang.ClassLoader instance
+ * corresponding {@link java.lang.ClassLoader} instance:<p>
+ * <i>pseudo javacode example</i>
+ * <pre>
+ * JavaClassLoader loader;
+ * JavaObject instance=loader.getObject();
+ * String classLoaderName=instance.getJavaClass().getName();
+ *
+ * </pre>
*
* @see java.lang.ClassLoader
*/
public interface JavaClassLoader {
/**
- * Get the set of classes which are defined in this JavaClassLoader.
- * @return an iterator over the collection of classes which are defined
- * in this JavaClassLoader
- *
+ * <p>
+ * Get the set of classes which are defined in this JavaClassLoader.
+ * Calling the {@link JavaClass#getClassLoader()} method on objects returned in this list will
+ * return this JavaClassLoader</p>
+ *
+ * <p>The returned list follows the standard semantics for javax.tools.diagnostics collections.</p>
+ * <p>The returned value is never null but can be an empty list.</p>
+ *
+ * @return an list of classes which are defined in this JavaClassLoader
* @see JavaClass
- * @see javax.tools.diagnostics.image.CorruptData
*/
List<JavaClass> getDefinedClasses();
/**
+ * <p>
* When a ClassLoader successfully delegates a findClass() request to
* another ClassLoader, the result of the delegation must be cached within
- * the internal structure so that the VM does not make repeated requests
+ * the internal structure so that the Java Virtual Machine does not make repeated requests
* for the same class.
+ * </p>
+ * The contents of the returned list is a superset of that returned by {@link #getDefinedClasses()}
+ * <p>
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections.</p>
+ * <p>The returned value is never null but can be an empty list.</p>
*
- * @return an iterator over the collection of classes which are defined
- * in this JavaClassLoader <i>or</i> which were found by delegation to
- * other JavaClassLoaders
+ * @return a list of classes which are defined in this JavaClassLoader
+ * <i>or</i> which were found by delegation to other JavaClassLoaders
*
* @see JavaClass
- * @see javax.tools.diagnostics.image.CorruptData
*/
List<JavaClass> getCachedClasses();
/**
- * Find a named class within this class loader. The class may have been
+ * Find a class by name within this class loader. The class may have been
* defined in this class loader, or this class loader may have delegated
* the load to another class loader and cached the result.
+ *
+ * The form of the name presented to this method should be as follows
+ * <pre>
+ * [ packagenamepart / ... ] (classname ) [ $innerclassname ...]
+ * </pre>
+ * <p>
+ * <i>Examples</i>
+ * </p>
+ * <ul>
+ * <li>To find the JavaClass that represents "java.lang.String" use findClass("java/lang/String")</li>
+ * <li>To find the JavaClass that represents "Foo.InnerClass.InnerInnerClass" in the default package use findClass("Foo$InnerClass$InnerInnerClass")</li>
+ * <li>To fine the JavaClass that represents "java.util.Map.Entry usefindClass("java/util/Map$Entry")
+ * </ul>
*
* @param name of the class to find. Packages should be separated by
* '/' instead of '.'
@@ -74,10 +104,14 @@
JavaClass findClass(String name) throws CorruptDataException;
/**
- * Get the java.lang.ClassLoader instance associated with this class loader.
- * @return a JavaObject representing the java.lang.ClassLoader instance
- * associated with this class loader, or null if there is no Java class
- * loader associated with this low-level class loader.
+ * Get the {@link java.lang.ClassLoader} instance (represented by a {@link JavaObject}
+ * associated with this class loader. If there is no associated class loader, for example the
+ * system class loader , then null will be returned.
+ *
+ * Further examination of the returned object is implementation specific.
+ *
+ * @return a JavaObject representing the {@link java.lang.ClassLoader} instance
+ *
* @throws CorruptDataException
*
* @see JavaObject
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaField.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaField.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaField.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaField.java Sun Jul 19 09:02:41 2009
@@ -18,12 +18,13 @@
/**
* Represents a field declaration.
- * It is modelled on java.lang.reflect.Field
+ * It is modelled on {@link java.lang.reflect.Field}
*/
public interface JavaField extends JavaMember {
/**
* Get the contents of an Object field
+ *
* @param object to fetch the field from. Ignored for static
* fields.
*
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaHeap.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaHeap.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaHeap.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaHeap.java Sun Jul 19 09:02:41 2009
@@ -15,26 +15,43 @@
import java.util.List;
+import javax.tools.diagnostics.image.ImageSection;
+
/**
- * Represents a heap of managed objects. There may be multiple heaps
- * within a JVM, for instance a generational heap and a class heap.
- * Additionally, heaps may consist of non-contiguous memory regions.
+ * Represents a single heap of managed objects.
+ *
+ * The heap can be viewed as an unordered collection of JavaObjects or as a region of storage
+ * within the Java Virtual Machiine instance.
+ *
+ * The heap commonly contains JavaObject instances that are reachable by navigating chains of {@link JavaReference}
+ * These references can be obtained from the {@link JavaRuntime#getHeapRoots()} method.
+ *
+ * A heap can contain instances which cannot be reached by the use of {@link JavaReference}
*
*/
public interface JavaHeap {
/**
- * Get the set of contiguous memory regions which form this heap.
- * @return an iterator over the collection of contiguous memory regions
- * which form this heap
+ * Get the set of memory regions that represent the memory layout of the heap.
+ * The actual make up of this list is implementation specific.
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections.
+ *
+ * The returned value is never null but can be an empty list.
+ *
+ * @return a list of {@link ImageSection} instances
+ *
*
* @see javax.tools.diagnostics.image.ImageSection
- * @see javax.tools.diagnostics.image.CorruptData
*/
- List getSections();
+ List<ImageSection> getSections();
/**
* Get a brief textual description of this heap.
+ * The value returned is implementation specific.
+ *
+ * The returned value is never null.
+ *
* @return a brief textual description of this heap
*/
String getName();
@@ -42,11 +59,13 @@
/**
* Get the set of objects which are stored in this heap.
*
- * @return an iterator over the collection of objects which
- * are stored in this heap
+ * @return a list of {@link JavaObject} objects which are stored in this heap
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections.
+ *
+ * The returned value is never null but can be an empty list.
*
* @see JavaObject
- * @see javax.tools.diagnostics.image.CorruptData
*/
List<JavaObject> getObjects();
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaMember.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaMember.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaMember.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaMember.java Sun Jul 19 09:02:41 2009
@@ -25,9 +25,9 @@
/**
* Get the set of modifiers for this field or method - a set of bits
- *
- * @return the modifiers for this field or method. The values for the constants representing
- * the modifiers can be obtained from java.lang.reflect.Modifier.
+ * The values for the constants representing the modifiers can be obtained from {@link java.lang.reflect.Modifier}.
+
+ * @return the modifiers for this field or method.
* @throws CorruptDataException
*
*/
@@ -35,6 +35,7 @@
/**
* Get the class which declares this field or method
+ *
* @return the JavaClass which declared this field or method
* @throws CorruptDataException
* @throws DataUnavailable
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaRuntime.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaRuntime.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaRuntime.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaRuntime.java Sun Jul 19 09:02:41 2009
@@ -38,10 +38,9 @@
public interface JavaRuntime extends ManagedRuntime {
/**
- * @remove Candidate for removal from specification as not useful
- *
* Get the object that represents the virtual machine
* @return the address of the JavaVM structure which represents this JVM instance in JNI
+ *
* @throws CorruptDataException
*/
ImagePointer getJavaVM() throws CorruptDataException;
@@ -60,12 +59,17 @@
/**
* Get the set of class loaders available in this Java Virtual Machine instance.
- *
+ * <p>
* Available in this context means class loaders that are participating in the class loader hierarchy.
* All class loaders are returned including any defined by the Java Virtual machine instance ifself.
+ * </p><p>
+ * Any structural relationships between class loaders in this list is not exposed. Recreation of the class loader
+ * graph within a Java Virtual Machine instance is beyond the scope of the API.
+ * </p>
+ * <p>At least one class loader must be returned in the resulting list.</p>
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections
*
- * At least one class loader must be returned in the resulting list.
- *
* @return a {@link java.util.List} of all of the class loaders within this Java Virtual Machine instance
*
* @see JavaClassLoader
@@ -73,7 +77,13 @@
List<JavaClassLoader> getJavaClassLoaders();
/**
- * Get the set of started Java Threads in this Java Virtual Machine instance.
+ * Get the set of Java Threads that have been started {@link java.lang.Thread#start()} in this Java Virtual Machine instance.
+ * This method does not return all instances of java.lang.Thread contained within the system. Only threads that have been started and have
+ * not yet stopped or exited are returned. Threads may not be in an active state when returned by this method.
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections
+ *
+ * The returned list is never null although it can be empty.
*
* @return a {@link java.util.List} of the JavaThreads in the runtime
*
@@ -85,10 +95,14 @@
/**
* Get the set of JavaMethod objects that have been compiled.
*
- * Compiled methods are ones that have been converted into native code.
+ * Compiled methods are methods that have been converted into native code by the Java Virtual Machine or related Just In Time Compiler
*
* There is no expectation that any method has been compiled. The returned list could be empty.
- *
+ * However any JavaMethod reachable though the API which would return a non empty list for calls to {@link JavaMethod#getCompiledSections()} must be contained within the list
+ * returned by this method.
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections
+ *
* @return a {@link java.util.List} of all of the JavaMethods in the JavaRuntime which
* have been compiled.
*
@@ -97,12 +111,17 @@
List<JavaMethod> getCompiledMethods();
/**
- * Provides access to the collection of monitors used in the JavaVM. This
- * collection includes both monitors associated with managed objects (e.g. object
- * monitors) and monitors associated with internal control structures (e.g.
- * raw monitors)
+ * Provides access to the collection of monitors used in the Java Virtual Machine. This
+ * collection can include monitors associated with managed objects (e.g. object
+ * monitors) and monitors associated with Java Virtual Machine internal control structures (e.g.
+ * raw monitors). Raw monitors are implementation specific.
*
- * @return an iterator over the collection of monitors
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections.
+ *
+ * The returned list is never null but could be empty.
+ *
+ * @return a list of monitors
*
* @see JavaMonitor
* @see javax.tools.diagnostics.image.CorruptData
@@ -110,22 +129,30 @@
List<JavaMonitor> getMonitors();
/**
- * Get the set of heaps known by the VM
- * @return an iterator for all of the Java heaps within this runtime. Heaps
- * may be specific to this JavaVM instance, or may be shared between multiple
- * JavaVM instances
+ * Get the set of heaps known by the Java Virtual Machine
+ * There may be multiple heaps within a Java Virtual Machine, for instance a generational heap and a class heap.
+ * Heaps may be specific to this Java Virtual Machine instance, or may be shared between multiple
+ * Java Virtual Machine instances.
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections.
*
+ * The returned list is never null and will always contain at least one JavaHeap object
+ *
+ * @return a list for all of the Java heaps within this runtime.
* @see JavaHeap
* @see javax.tools.diagnostics.image.CorruptData
*/
List<JavaHeap> getHeaps();
/**
- * Get the set of object and class roots known to the VM.
- * Stack frame roots are not included in the set. Instead, they can be retrieved using JavaStackFrame.getHeapRoots().
- *
- * @return an iterator over the collection of JavaReferences representing the known global heap roots within this runtime.
- *
+ * Get the complete set of object and class roots known to the Java Virtual Machine
+ *
+ * @return a list of JavaReferences representing the known global heap roots within this runtime.
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections.
+ *
+ * The returned list is never null but can be empty.
+
* @see JavaReference
* @see JavaStackFrame
* @see javax.tools.diagnostics.image.CorruptData
@@ -134,6 +161,8 @@
List<JavaReference> getHeapRoots();
/**
+ * @remove candidate for removal as its an arbitary implementation specific method
+ *
* Fetches implementation specific trace buffers, like the verbose GC buffer.
*
* @param bufferName a String naming the buffer to be fetched
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMInitArgs.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMInitArgs.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMInitArgs.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMInitArgs.java Sun Jul 19 09:02:41 2009
@@ -21,13 +21,16 @@
/**
- * This class models the JavaVMInitArgs C structure passed to JNI_CreateJavaVM
- * to create this VM.
+ * This class models the JavaVMInitArgs C structure passed to <a href="http://java.sun.com/javase/6/docs/technotes/guides/jni/spec/invocation.html#wp16334">JNI_CreateJavaVM</a>
+ * to create this Java Virtual Machine
+ *
+ * Typically the options passed to the JVM are similar but necessarily identical to these used to invoke the Java Virtual Machine from a command line.
+ *
*/
public interface JavaVMInitArgs {
/**
- * The JNI specified version constant for the Java 1.1 version of JNI
+ * The JNI specified version constant for the Java 1.1 version of JNI
*/
public static final int JNI_VERSION_1_1 = 0x00010001;
@@ -42,8 +45,13 @@
public static final int JNI_VERSION_1_4 = 0x00010004;
/**
- * Fetch the JNI version from the JavaVMInitArgs structure used to create this VM.
- * See the JNI specification for the meaning for this field.
+ * The JNI specified version constant for the Java 1.6 version of JNI
+ */
+ public static final int JNI_VERSION_1_6 = 0x00010006;
+
+ /**
+ * Fetch the JNI version from the JavaVMInitArgs structure used to create this Java Virtual Machine.
+ * See the <a href="http://java.sun.com/javase/6/docs/technotes/guides/jni/spec/functions.html#wp15951">JNI specification</a> for the meaning for this field.
*
* @return the JNI version
* @throws DataUnavailable
@@ -52,19 +60,24 @@
int getVersion() throws DataUnavailable, CorruptDataException;
/**
- * Fetch the ignoreUnrecognized field from the JavaVMInitArgs structure used to create this VM.
- * See the JNI specification for the meaning of this field.
+ * Fetch the ignoreUnrecognized field from the JavaVMInitArgs structure used to create this Java Virtual Machine.
+ * See the <a href="http://java.sun.com/javase/6/docs/technotes/guides/jni/spec/functions.html#wp15951">JNI specification</a> for the meaning for this field.
*
- * @return true if ignoreUnrecognized was set to a non-zero value with the VM was invoked
+ * @return true if ignoreUnrecognized was set to a non-zero value when the Java Virtual Machine was invoked
* @throws DataUnavailable
* @throws CorruptDataException
*/
boolean getIgnoreUnrecognized() throws DataUnavailable, CorruptDataException;
/**
- * Fetch the options used to start this VM, in the order they were originally specified.
+ * Fetch the options used to start this Java Virtual Machine, in the order they were originally specified.
+ *
+ * The returned list follows the standard semantics for javax.tools.diagnostics collections
+ *
+ * The order of the options returned in the list is the same as that passed to the to <a href="http://java.sun.com/javase/6/docs/technotes/guides/jni/spec/invocation.html#wp16334">JNI_CreateJavaVM</a> function.
+ * A list is always returned but could be empty
*
- * @return an Iterator over the collection of JavaVMOptions
+ * @return an List of JavaVMOptions
* @throws DataUnavailable
*
* @see JavaVMOption
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMOption.java
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMOption.java?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMOption.java (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.api/src/main/java/javax/tools/diagnostics/java/JavaVMOption.java Sun Jul 19 09:02:41 2009
@@ -18,10 +18,10 @@
import javax.tools.diagnostics.image.ImagePointer;
/**
- * This class models the JavaVMOption C structures passed to JNI_CreateJavaVM
- * to create this VM.
+ * This class models the JavaVMOption C structures passed to the JNI invocation API entry point <a href="http://java.sun.com/javase/6/docs/technotes/guides/jni/spec/invocation.html#wp16334">JNI_CreateJavaVM</a>
+ * used to create a Java Virtual Machine.
*
- * Each JavaVMOption consists of two components:
+ * Each JavaVMOption consists of two components :
* <ol>
* <li> an optionString string, used to identify the option.</li>
* <li> an extraInfo pointer, used to pass additional information. This component is usually NULL.</li>
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.classpath
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.classpath?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.classpath (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.classpath Sun Jul 19 09:02:41 2009
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
+ <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.project
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.project?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.project (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.project Sun Jul 19 09:02:41 2009
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>kato.docs</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.maven.ide.eclipse.maven2Builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.maven.ide.eclipse.maven2Nature</nature>
+ </natures>
+</projectDescription>
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.eclipse.jdt.core.prefs
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.eclipse.jdt.core.prefs?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.eclipse.jdt.core.prefs (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.eclipse.jdt.core.prefs Sun Jul 19 09:02:41 2009
@@ -0,0 +1,5 @@
+#Thu Jul 16 08:21:03 BST 2009
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
+org.eclipse.jdt.core.compiler.compliance=1.6
+org.eclipse.jdt.core.compiler.source=1.6
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.maven.ide.eclipse.prefs
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.maven.ide.eclipse.prefs?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.maven.ide.eclipse.prefs (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/.settings/org.maven.ide.eclipse.prefs Sun Jul 19 09:02:41 2009
@@ -0,0 +1,9 @@
+#Thu Jul 16 08:21:03 BST 2009
+activeProfiles=
+eclipse.preferences.version=1
+fullBuildGoals=process-test-resources
+includeModules=false
+resolveWorkspaceProjects=true
+resourceFilterGoals=process-resources resources\:testResources
+skipCompilerPlugin=true
+version=1
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/pom.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/pom.xml?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/pom.xml (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/pom.xml Sun Jul 19 09:02:41 2009
@@ -0,0 +1,99 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <artifactId>kato</artifactId>
+ <groupId>org.apache.kato</groupId>
+ <version>0.0.1-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.kato</groupId>
+ <artifactId>kato.docs</artifactId>
+ <packaging>pom</packaging>
+ <version>0.0.1-SNAPSHOT</version>
+
+ <build>
+ <plugins>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <version>1.3</version>
+ <executions>
+ <execution>
+ <id>compile</id>
+ <phase>compile</phase>
+ <configuration>
+ <tasks>
+ <ant antfile="buildjavadoc.xml" dir="src/ant">
+ <property name="src" location="src" />
+ <property name="target" location="${project.build.directory}" />
+ <property name="apisrc" location="../kato.api/src/main/java" />
+ <property name="build" value="${project.build.directory}/spec" />
+ <property name="path" refid="maven.runtime.classpath" />
+ </ant>
+ </tasks>
+ </configuration>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ </execution>
+ </executions>
+ <dependencies>
+ <dependency>
+ <groupId>ant</groupId>
+ <artifactId>ant-trax</artifactId>
+ <version>1.6.5</version>
+ </dependency>
+
+
+ </dependencies>
+ </plugin>
+
+
+ <plugin>
+ <groupId>com.agilejava.docbkx</groupId>
+ <artifactId>docbkx-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <goals>
+ <!--
+ <goal>generate-javahelp</goal>
+ <goal>generate-eclipse</goal>
+ -->
+ <goal>generate-pdf</goal>
+ </goals>
+ <phase>compile</phase>
+ </execution>
+ </executions>
+ <dependencies>
+ <dependency>
+ <groupId>org.docbook</groupId>
+ <artifactId>docbook-xml</artifactId>
+ <version>4.4</version>
+ <scope>runtime</scope>
+ </dependency>
+ </dependencies>
+ <configuration>
+ <xincludeSupported>true</xincludeSupported>
+ <chunkedOutput>true</chunkedOutput>
+ <footerRule>true</footerRule>
+ <foCustomization>src/docbkx/fo.xsl</foCustomization>
+
+ <draftWatermarkImage>http://docbook.sourceforge.net/release/images/draft.png</draftWatermarkImage>
+ </configuration>
+
+ </plugin>
+
+
+
+ </plugins>
+ </build>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.kato</groupId>
+ <artifactId>kato.anttasks</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+
+ </dependency>
+ </dependencies>
+</project>
\ No newline at end of file
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/ant/buildjavadoc.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/ant/buildjavadoc.xml?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/ant/buildjavadoc.xml (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/ant/buildjavadoc.xml Sun Jul 19 09:02:41 2009
@@ -0,0 +1,63 @@
+<project default="build">
+
+ <property name="java.src" location="${src}/main/java"/>
+ <property name="style.src" location="${src}/xslt"/>
+ <property name="book.src" location="${src}/books/spec/en"/>
+ <property name="book.dir" location="${build}"/>
+ <property name="book.dir.xml" location="${book.dir}/xml"/>
+ <property name="javadoc.xml" location="${book.dir.xml}/javadoc.xml"/>
+
+ <property name="packagelist.xml" location="${build}/chapters/sections/packagelist.xml"/>
+ <property name="packagecontents.xml" location="${build}/chapters/packagecontents.xml"/>
+
+ <taskdef resource="org/apache/kato/anttasks/anttasks.properties">
+ <classpath path="${path}"/>
+ </taskdef>
+ <!--
+ <taskdef name="fop" classname="org.apache.fop.tools.anttasks.Fop">
+ <classpath path="${path}"/>
+ </taskdef>
+ -->
+ <target name="clean" >
+ <!-- remove the old docbook -->
+ <delete dir="${target}/docbkx" failonerror="true" includeemptydirs="true"/>
+
+ </target>
+
+ <target name="build" depends="clean">
+
+
+ <!-- create a place to build the book -->
+ <mkdir dir="${book.dir.xml}"/>
+
+ <!-- copy in the static parts -->
+ <!--
+
+ <copy todir="${book.dir}" >
+ <fileset dir="${book.src}" />
+ </copy>
+ -->
+
+ <!-- create xml definition of the javadoc -->
+
+ <xmljavadoc sourcepath="${apisrc}" output="${javadoc.xml}" docletpath="${path}">
+ <fileset dir="${apisrc}"/>
+ <link href="http://java.sun.com/javase/6/docs/api/"/>
+
+ </xmljavadoc>
+
+ <!-- create the package list book page -->
+
+ <xslt style="${style.src}/packagelist.xslt"
+ in="${javadoc.xml}"
+ out="${packagelist.xml}" >
+
+ </xslt>
+ <xslt style="${style.src}/packagecontents.xslt"
+ in="${javadoc.xml}"
+ out="${packagecontents.xml}" >
+
+ </xslt>
+
+ </target>
+</project>
\ No newline at end of file
Propchange: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/ant/buildjavadoc.xml
------------------------------------------------------------------------------
svn:executable = *
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/API.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/API.xml?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/API.xml (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/API.xml Sun Jul 19 09:02:41 2009
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<chapter version="5.0" xml:id="api"
+ xmlns="http://docbook.org/ns/docbook"
+ xmlns:xlink="http://www.w3.org/1999/xlink"
+ xmlns:xi="http://www.w3.org/2001/XInclude"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns:mml="http://www.w3.org/1998/Math/MathML"
+ xmlns:html="http://www.w3.org/1999/xhtml"
+ xmlns:db="http://docbook.org/ns/docbook">
+ <title>Using the Application Programming Interface</title>
+
+ <section xml:id="api.details">
+ <title>Structure</title>
+
+ <para>JSR 326 consists of a series of packages that are separated into three logical groups
+ </para>
+ <itemizedlist>
+ <listitem><para>Common facilities and factory discovery </para></listitem>
+ <listitem><para>Java Runtime abstraction</para></listitem>
+ <listitem><para>Process abstraction</para></listitem>
+</itemizedlist>
+
+ </section>
+
+ <xi:include href="../../../target/spec/chapters/sections/packagelist.xml" />
+
+</chapter>
\ No newline at end of file
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/Introduction.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/Introduction.xml?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/Introduction.xml (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/chapters/Introduction.xml Sun Jul 19 09:02:41 2009
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<chapter version="5.0" xml:id="introduction"
+ xmlns="http://docbook.org/ns/docbook"
+ xmlns:xlink="http://www.w3.org/1999/xlink"
+ xmlns:xi="http://www.w3.org/2001/XInclude"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns:mml="http://www.w3.org/1998/Math/MathML"
+ xmlns:html="http://www.w3.org/1999/xhtml"
+ xmlns:db="http://docbook.org/ns/docbook">
+ <title>Introduction</title>
+
+ <section xml:id="introduction.jsr326">
+ <title>What is JSR 326?</title>
+
+ <para>Places to visit</para>
+
+ <para><uri xlink:href="http://cwiki.apache.org/KATO/" xlink:type="simple">Kato Wiki</uri>
+ </para>
+ </section>
+
+
+</chapter>
\ No newline at end of file
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/fo.xsl
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/fo.xsl?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/fo.xsl (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/fo.xsl Sun Jul 19 09:02:41 2009
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:fo="http://www.w3.org/1999/XSL/Format"
+ version="1.0">
+ <!-- import the main stylesheet, here pointing to fo/docbook.xsl -->
+ <xsl:import href="urn:docbkx:stylesheet"/>
+ <!-- highlight.xsl must be imported in order to enable highlighting support, highlightSource=1 parameter
+ is not sufficient -->
+ <xsl:import href="urn:docbkx:stylesheet/highlight.xsl"/>
+
+
+ <!-- some customization -->
+ <xsl:attribute-set name="section.title.level1.properties">
+ <xsl:attribute name="border-top">0.5pt solid black</xsl:attribute>
+ <xsl:attribute name="border-bottom">0.5pt solid black</xsl:attribute>
+ <xsl:attribute name="padding-top">6pt</xsl:attribute>
+ <xsl:attribute name="padding-bottom">3pt</xsl:attribute>
+ </xsl:attribute-set>
+
+<xsl:attribute-set name="section.title.level1.properties">
+ <xsl:attribute name="font-size">
+ <xsl:value-of select="$body.font.master * 2.0736"></xsl:value-of>
+ <xsl:text>pt</xsl:text>
+ </xsl:attribute>
+</xsl:attribute-set>
+
+<xsl:attribute-set name="section.title.level2.properties">
+ <xsl:attribute name="font-size">
+ <xsl:value-of select="$body.font.master * 1.728"></xsl:value-of>
+ <xsl:text>pt</xsl:text>
+ </xsl:attribute>
+</xsl:attribute-set>
+
+<xsl:attribute-set name="section.title.level3.properties">
+ <xsl:attribute name="font-size">
+ <xsl:value-of select="$body.font.master * 1.44"></xsl:value-of>
+ <xsl:text>pt</xsl:text>
+ </xsl:attribute>
+</xsl:attribute-set>
+<!--
+<xsl:attribute-set name="section.level2.properties">
+ <xsl:attribute name="break-before">page</xsl:attribute>
+</xsl:attribute-set>
+ -->
+
+
+</xsl:stylesheet>
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/spec.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/spec.xml?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/spec.xml (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/docbkx/spec.xml Sun Jul 19 09:02:41 2009
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<book version="5.0" xmlns="http://docbook.org/ns/docbook"
+ xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude"
+ xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML"
+ xmlns:html="http://www.w3.org/1999/xhtml" xmlns:db="http://docbook.org/ns/docbook">
+
+ <info>
+ <title>JSR 326 Post mortem JVM Diagnostics API</title>
+ <subtitle>Early Draft Review</subtitle>
+ <pubdate><?dbtimestamp format="Y-m-d"?>
+ </pubdate>
+ <copyright>
+ <year><?dbtimestamp format="Y"?>
+ </year>
+ <holder>Apache Software Foundation</holder>
+ </copyright>
+
+
+ <legalnotice>
+ <para>
+ licence goes here
+ </para>
+ </legalnotice>
+
+
+
+ </info>
+
+
+
+<preface>
+<title>Preface</title>
+
+<section>
+<title>Audience</title>
+</section>
+<section>
+<title>Prerequisites</title>
+</section>
+<section>
+<title>References</title>
+</section>
+<section>
+<title>Related Documentation</title>
+</section>
+<section>
+<title>How to comment on the specification</title>
+</section>
+</preface>
+
+
+ <xi:include href="chapters/Introduction.xml" />
+ <xi:include href="chapters/API.xml" />
+ <xi:include href="../../target/spec/chapters/packagecontents.xml" />
+</book>
\ No newline at end of file
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagecontents.xslt
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagecontents.xslt?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagecontents.xslt (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagecontents.xslt Sun Jul 19 09:02:41 2009
@@ -0,0 +1,156 @@
+<?xml version="1.0"?>
+
+<xsl:stylesheet version="1.0"
+xmlns:html="http://www.w3.org/1999/xhtml"
+xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+xmlns:fo="http://www.w3.org/1999/XSL/Format"
+xmlns:db="http://docbook.org/ns/docbook"
+xmlns:javadoc="http://apache.org/javadoc"
+xmlns="http://docbook.org/ns/docbook">
+
+<xsl:template match="/">
+
+<chapter version="5.0" xml:id="api-reference">
+ <title>API Reference</title>
+ <para>This chapter contains the details of the Java classes that comprise the API.</para>
+ <xsl:for-each select="javadoc:javadoc/javadoc:package">
+ <xsl:sort select="@name"/>
+
+ <sect1>
+
+ <xsl:attribute name="xml:id">
+ <xsl:value-of select="@name" />
+ </xsl:attribute>
+
+
+ <title><xsl:value-of select="@name"/></title>
+ <section>
+ <xsl:copy-of select="javadoc:comment/*"/>
+ </section>
+ <xsl:if test="count(./javadoc:interface)>0">
+
+ <table border="1">
+ <xsl:attribute name="xml:id">interfacelist.
+ <xsl:value-of select="@name" />
+ </xsl:attribute>
+ <caption>Interface Summary</caption>
+ <thead>
+ <tr>
+ <th colspan="1">Name</th>
+ <th colspan="2">Summary</th>
+ </tr>
+ </thead>
+ <tbody>
+
+ <xsl:for-each select="./javadoc:interface">
+
+ <tr>
+ <td colspan="1"><xsl:value-of select="@name"/></td>
+ <td colspan="2"><xsl:value-of select="javadoc:summary"/></td>
+ </tr>
+
+ </xsl:for-each>
+ </tbody>
+ </table>
+ </xsl:if>
+
+ <xsl:if test="count(./javadoc:class)>0">
+ <table border="1">
+ <xsl:attribute name="xml:id">classlist.
+ <xsl:value-of select="@name" />
+ </xsl:attribute>
+ <caption>Class Summary</caption>
+ <thead>
+ <tr bgcolor="red">
+ <td>Name</td>
+ <td>Summary</td>
+ </tr>
+ </thead>
+ <tbody>
+ <xsl:for-each select="./javadoc:class">
+ <tr>
+ <td><xsl:value-of select="@name"/></td>
+ <td><xsl:value-of select="javadoc:summary"/></td>
+ </tr>
+ </xsl:for-each>
+ </tbody>
+ </table>
+ </xsl:if>
+
+
+
+ <!-- list class details -->
+ <xsl:if test="count(./javadoc:interface | ./javadoc:class)>0">
+ <sect2>
+ <title>Details</title>
+ <xsl:for-each select="./javadoc:class | ./javadoc:interface">
+ <sect3>
+ <title><xsl:value-of select="@name"/></title>
+ <section><xsl:copy-of select="comment/*"/></section>
+ <xsl:if test="count(./javadoc:field)>0">
+ <xsl:for-each select="./javadoc:field">
+ <para>Field</para>
+ </xsl:for-each>
+ </xsl:if>
+ <xsl:if test="count(./javadoc:constructor)>0">
+ <table border="1">
+ <xsl:attribute name="xml:id">constructors.
+ <xsl:value-of select="@name" />
+ </xsl:attribute>
+ <caption>Constructor Summary</caption>
+ <thead>
+ <tr bgcolor="red">
+ <td>Signature</td>
+ <td>Summary</td>
+ </tr>
+ </thead>
+ <tbody>
+ <xsl:for-each select="./javadoc:constructor">
+ <tr>
+ <td><xsl:value-of select="../@name"/><xsl:value-of select="@signature"/></td>
+ <td><xsl:value-of select="javadoc:summary"/></td>
+ </tr>
+ </xsl:for-each>
+ </tbody>
+ </table>
+ </xsl:if>
+ <xsl:if test="count(./javadoc:method)>0">
+ <table border="1">
+ <xsl:attribute name="xml:id">methods.
+ <xsl:value-of select="@name" />
+ </xsl:attribute>
+ <caption>Method Summary</caption>
+ <thead>
+ <tr bgcolor="red">
+ <td>Return Type</td>
+ <td>Signature</td>
+ <td>Summary</td>
+ </tr>
+ </thead>
+ <tbody>
+
+ <xsl:for-each select="./javadoc:method">
+ <tr>
+ <td><xsl:value-of select="javadoc:modifiers"/><xsl:text> </xsl:text><xsl:value-of select="javadoc:returntype/javadoc:name"/></td>
+ <td><xsl:value-of select="@name"/><xsl:value-of select="@signature"/></td>
+ <td><xsl:value-of select="javadoc:summary"/></td>
+ </tr>
+ </xsl:for-each>
+ </tbody>
+ </table>
+ </xsl:if>
+ </sect3>
+
+ </xsl:for-each>
+ </sect2>
+ </xsl:if>
+
+ </sect1>
+ </xsl:for-each>
+
+</chapter>
+
+ </xsl:template>
+
+
+</xsl:stylesheet>
\ No newline at end of file
Added: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagelist.xslt
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagelist.xslt?rev=795498&view=auto
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagelist.xslt (added)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/kato.docs/src/xslt/packagelist.xslt Sun Jul 19 09:02:41 2009
@@ -0,0 +1,44 @@
+<?xml version="1.0"?>
+
+<xsl:stylesheet version="1.0"
+ xmlns:html="http://www.w3.org/1999/xhtml"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:fo="http://www.w3.org/1999/XSL/Format"
+ xmlns:db="http://docbook.org/ns/docbook"
+ xmlns:javadoc="http://apache.org/javadoc"
+ xmlns="http://docbook.org/ns/docbook">
+
+<xsl:template match="/">
+
+<db:section version="5.0" xml:id="packages" >
+
+ <table table-layout="fixed" frame='all' id="packagelist"><title>Packages</title>
+<tgroup cols='2' align='left' colsep='1' rowsep='1'>
+<colspec colname='c1'/>
+<colspec colname='c2'/>
+<thead>
+<row>
+ <entry>Name</entry>
+ <entry>Title</entry>
+</row>
+</thead>
+<tbody>
+
+ <xsl:for-each select="javadoc:javadoc/javadoc:package">
+
+ <row>
+ <entry><para><xsl:value-of select="@name"/></para>para></entry>
+ <entry><para><xsl:value-of select="summary"/></para></entry>
+ </row>
+ </xsl:for-each>
+
+</tbody>
+</tgroup>
+</table>
+</db:section>
+
+
+ </xsl:template>
+
+
+</xsl:stylesheet>
\ No newline at end of file
Modified: incubator/kato/branches/experimental/maven_restructure/org.apache.kato/pom.xml
URL: http://svn.apache.org/viewvc/incubator/kato/branches/experimental/maven_restructure/org.apache.kato/pom.xml?rev=795498&r1=795497&r2=795498&view=diff
==============================================================================
--- incubator/kato/branches/experimental/maven_restructure/org.apache.kato/pom.xml (original)
+++ incubator/kato/branches/experimental/maven_restructure/org.apache.kato/pom.xml Sun Jul 19 09:02:41 2009
@@ -19,6 +19,7 @@
<module>kato.demo.tomcat</module>
<module>kato.anttasks</module>
<module>kato.tck.testsuite</module>
+ <module>kato.docs</module>
</modules>
<build>