legerdemain (10) [Avatar] Offline
#1
Hello, I seem to have a problem running xdoclet on files that have a package statement in them. If I remove the package statement, I can get an xdoclet task to run correctly, but if the package statement is in the java file that the xdoclet task is run on, it just skips over it entirely. The package statement can be any package statement. Any ideas why this is occurring? Any suggestions? I could really use the help on this as its for a very important project, thank you.
orb (16) [Avatar] Offline
#2
Re: Package statements cause problems!
Can you post your build file? (the xdoclet parts) The only thing I can think of is that you aren't including all the source files in the fileset.
legerdemain (10) [Avatar] Offline
#3
Re: Package statements cause problems!
Thank you for your response. Here is my buildfile, I apologize for the length but I pasted the entire thing. I'm really in a rather serious bind here and greatly appreciate any help, thank you.

<project name="JB" default="compile" basedir=".">

<property environment="env"/>
<property name="src.dir" value="${basedir}/src"/>
<property name="build.dir" value="${basedir}/build"/>
<property name="todo.dir" value="${basedir}/todo"/>
<property name="lib.dir" location="${env.ANT_HOME}/lib"/>
<property name="xdoclet.lib.dir" location="${env.XDOCLET_HOME}lib"/>

<path id="xdoclet.lib.path">
<fileset dir="${lib.dir}" includes="*.jar"/>
<fileset dir="${xdoclet.lib.dir}" includes="*.jar"/>
</path>

<!-- =================================================================== -->
<!-- TaskDefs -->
<!-- =================================================================== -->
<taskdef name="documentdoclet" >
classname="xdoclet.modules.doc.DocumentDocletTask"
classpathref="xdoclet.lib.path" />

<taskdef name="xdoclet" >
classname="xdoclet.DocletTask"
classpathref="xdoclet.lib.path" />

<!-- =================================================================== -->
<!-- Init -->
<!-- =================================================================== -->
<target name="init">
<tstamp/>
<mkdir dir="${build.dir}"/>
</target>

<!-- =================================================================== -->
<!-- Todo -->
<!-- =================================================================== -->
<!-- <target name="todo"> <br /> <documentdoclet destdir="${basedir}/todo"> <br /> <fileset dir="${src.dir}"> <br /> <include name="**/*.java" /> <br /> </fileset> <br /> <info /> <br /> </documentdoclet> <br /> </target> <br /> -->
<!-- =================================================================== -->
<!-- Summary -->
<!-- =================================================================== -->
<target name="summary" depends="init">
<xdoclet destdir="${build.dir}">
<fileset dir="${src.dir}" includes="**/*.java" />
<template templateFile="summary.xdt" >
destinationfile="summary.txt" />
</xdoclet>
</target>

<!-- =================================================================== -->
<!-- Transform -->
<!-- =================================================================== -->
<target name="transform" depends="init">
<xdoclet destdir="${src.dir}" addedTags="@xdoclet-generated">
<fileset dir="${src.dir}" includes="**/*.java" />
<template acceptInterfaces="false" >
acceptAbstractClasses="false"
templateFile="transform.xdt"
destinationfile="{0}Bean.java" />
</xdoclet>
</target>

<!-- =================================================================== -->
<!-- Compile -->
<!-- =================================================================== -->
<target name="compile" depends="init">

<echo>+---------------------------------------------------+</echo>
<echo>| |</echo>
<echo>| C O M P I L I N G S O U R C E S |</echo>
<echo>| |</echo>
<echo>+---------------------------------------------------+</echo>

<javac srcdir="${src.dir}" destdir="${build.dir}"/>

</target>

<!-- =================================================================== -->
<!-- Clean -->
<!-- =================================================================== -->
<target name="clean">
<delete dir="${todo.dir}"/>
<delete dir="${build.dir}"/>
</target>

</project>