Code Location: git://github.com/egonw/cdk.gitmaster
Browse
/
Download File
javadoc.xml
<project name="CDK" default="html" basedir=".">

    <property file="build.props"/>

    <!-- $Id$ -->

    <property name="vecmath.src" value="gcj/vecmath" />
    <property name="vecmath.javadoc.dir" value="doc/vecmath/api" />

    <property name="src" value="src" />
    <property name="javadoc.dir" value="doc/cdk-javadoc-${version}" />

    <property name="pathtojava3d" value="" />

    <!-- directories -->
    <property name="build" value="build" />
    <property name="lib" value="jar" />
    <property name="devellib" value="develjar" />
    <property name="dist" value="dist" />
    <property name="metainf" value="${src}/META-INF" />

	<!-- Used in the html task to properly link to java library classes -->
	<property name="javaURL" value="http://java.sun.com/j2se/1.5.0/docs/api/"/>
	
    <path id="project.class.path">
        <pathelement location="." />
        <fileset dir="jar">
            <include name="*.jar" />
        </fileset>
        <fileset dir="${pathtojava3d}">
            <include name="*.jar" />
        </fileset>
    </path>

    <target name="html" depends="compileTaglets">
        <mkdir dir="${javadoc.dir}" />

        <!-- Call javacc target in build.xml to re-generate the source code -->
        <ant antfile="build.xml" target="javacc"/>
   <tstamp>
                <format property="TODAY_SVN" pattern="yyyyMMdd" locale="en" />
            </tstamp>
        <javadoc destdir="${javadoc.dir}"
                 author="true" version="true" use="true"
                 public="true"
                 encoding="UTF-8"
                 windowtitle="CDK ${version} API - created on ${TODAY_SVN}">
            <classpath>
                <pathelement location="." />
                <fileset dir="${lib}">
                    <include name="*.jar" />
                </fileset>
                <pathelement location="." />
                <fileset dir="${lib}/jena">
                    <include name="*.jar" />
                </fileset>
                <fileset dir="${devellib}">
                    <include name="*.jar" />
                </fileset>
                 <dirset dir="src/main">
                     <include name="net/**/*"/>
                 </dirset>
            </classpath>
            <tag name="cdk.set" scope="all" description="Belongs to the set:" />
            <tag name="cdk.keyword" scope="all" description="Keywords:" />
            <tag name="cdk.created" scope="all" description="Created on:" />
            <tag name="cdk.require" scope="all" description="Requires:" />
            <tag name="cdk.depends" scope="all" description="Required library to be able to run this class:" />
            <tag name="cdk.builddepends" scope="all" description="Required library to be able to compile this class:" />
            <tag name="cdk.todo" scope="all" description="To do:" />
            <tag name="cdk.license" scope="all" description="License:" />
            <taglet name="net.sf.cdk.tools.doclets.CDKCiteTaglet" path="jar/xom-1.1.jar:${build}" />
            <taglet name="net.sf.cdk.tools.doclets.CDKModuleTaglet" path="jar/xom-1.1.jar:${build}" />
            <taglet name="net.sf.cdk.tools.doclets.CDKBugTaglet" path="jar/xom-1.1.jar:${build}" />
            <taglet name="net.sf.cdk.tools.doclets.CDKDictRefTaglet" path="jar/xom-1.1.jar:${build}" />
            <taglet name="net.sf.cdk.tools.doclets.CDKInChITaglet" path="jar/xom-1.1.jar:${build}" />
            <taglet name="net.sf.cdk.tools.doclets.CDKThreadSafeTaglet" path="jar/xom-1.1.jar:${build}" />
            <taglet name="net.sf.cdk.tools.doclets.CDKThreadNonSafeTaglet" path="jar/xom-1.1.jar:${build}" />
            <taglet name="net.sf.cdk.tools.doclets.CDKGitTaglet" path="jar/xom-1.1.jar:${build}" />
            <taglet name="net.sf.cdk.tools.doclets.CDKIOOptionsTaglet" path="jar/xom-1.1.jar:${build}">
              <path>
                <pathelement location="." />
                <fileset dir="dist/jar">
                  <include name="*.jar" />
                </fileset>
                <fileset dir="${lib}">
                  <include name="*.jar" />
                </fileset>
                <fileset dir="${lib}/jena">
                  <include name="*.jar" />
                </fileset>
              </path>
            </taglet>
            <packageset dir="${src}/main" defaultexcludes="yes">
                <include name="org/openscience/cdk/**" />
            </packageset>
        	<link href="${javaURL}"/>
        </javadoc>
    </target>

    <target name="vecmath.html">
        <mkdir dir="${vecmath.javadoc.dir}" />

        <javadoc destdir="${vecmath.javadoc.dir}"
                 author="true" version="true" use="true"
                 public="true"
                 windowtitle="VecMath API">
            <classpath refid="project.class.path" />
            <packageset dir="${vecmath.src}" defaultexcludes="yes">
                <include name="javax/vecmath/**" />
            </packageset>
        </javadoc>
    </target>

  <target name="jjdoc" description="Create JJDoc documentation from the .jj file">   
    <mkdir dir="doc/iupac-parser"/>
    <jjdoc target="${src}/main/org/openscience/cdk/iupac/parser/NomParser.jj"
      outputfile="doc/iupac-parser/ParserBNF.html"
      javacchome="jar"/>
  </target>

  <target name="ojdcheck" depends="compileDocTests">
      <antcall target="ojdcheck-module"><param name="module" value="interfaces"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="core"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="cip"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="data"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="datadebug"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="standard"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="atomtype"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="dict"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="io"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="ioformats"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="iordf"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="inchi"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="extra"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="fingerprint"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="formula"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="render"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="renderextra"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="reaction"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="libiocml"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="libiomd"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="log4j"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="builder3d"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="smiles"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="smarts"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="sdg"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="tautomer"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="forcefield"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="pdb"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="qsar"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="qsaratomic"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="qsarbond"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="qsarionpot"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="qsarmolecular"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="qsarprotein"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="pcore"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="structgen"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="valencycheck"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="charges"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="diff"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="smsd"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="signature"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="renderawt"/></antcall>
      <antcall target="ojdcheck-module"><param name="module" value="renderbasic"/></antcall>
    </target>

    <target name="ojdcheck-module">
        <mkdir dir="reports/ojdcheck/"/>
        <mkdir dir="${build}/src/${module}"/>
        <copy todir="${build}/src/${module}">
            <fileset dir="${src}/main">
                <includesfile name="${build}/${module}.javafiles"/>
            </fileset>
        </copy>

        <!-- check for availability for meta info files -->
        <available file="${metainf}/${module}.cdkdepends" property="module.cdkdepends.present"/>
        <available file="${metainf}/${module}.libdepends" property="module.libdepends.present"/>
        <available file="${metainf}/${module}.devellibdepends" property="module.devellibdepends.present"/>

    	<javadoc private="false" public="true">
        	<classpath>
        	    <fileset dir="${dist}/jar" >
        	        <exclude name="**/*" unless="module.cdkdepends.present" />
        	        <includesfile name="${metainf}/${module}.cdkdepends" if="module.cdkdepends.present" />
        	    </fileset>
        	    <fileset dir="${lib}" >
        	        <exclude name="**/*" unless="module.libdepends.present" />
        	        <includesfile name="${metainf}/${module}.libdepends" if="module.libdepends.present" />
        	    </fileset>
        	    <fileset dir="${devellib}">
        	        <exclude name="**/*" unless="module.devellibdepends.present" />
        	        <includesfile name="${metainf}/${module}.devellibdepends" if="module.devellibdepends.present" />
                    </fileset>
        	</classpath>

            <doclet name="com.github.ojdcheck.OpenJavaDocCheck"
                    path="develjar/ojdcheck.jar:src/main">
              <param name="-xhtml"/>
              <param name="-file"
                    value="reports/ojdcheck/${module}.html"/>
              <param name="-tests"
                    value="net.sf.cdk.tools.checkdoctest.MissingGithashTagletTest,net.sf.cdk.tools.checkdoctest.MissingModuleTagletTest,net.sf.cdk.tools.checkdoctest.IncorrectBugNumberTagletTest"/>
            </doclet>
            <sourcepath>
              <pathelement path="${build}/src/${module}"/>
            </sourcepath>
        </javadoc>
    </target>

  <target name="compileTaglets" id="compileTaglets">
    <javac srcdir="src/main" destdir="${build}"
           includes="net/sf/cdk/tools/**/*Taglet.java" debug="on" optimize="off">
      <classpath>
          <fileset dir="jar/">
              <include name="xom-1.1.jar" />
          </fileset>
      </classpath>
    </javac>
  </target>

  <target name="compileDocTests" id="compileDocTests">
    <javac srcdir="src/main" destdir="src/main"
           includes="net/sf/cdk/tools/checkdoctest/*Test.java"
           debug="on" optimize="off">
      <classpath>
        <fileset dir="develjar/">
          <include name="ojdcheck.jar" />
          <include name="com-sun-*.jar" />
        </fileset>
      </classpath>
    </javac>
  </target>
</project>