<?xml version="1.0"?> <!-- NQ optimization build time enhancement sample. --> <project name="nqenhance" default="buildall"> <!-- Set up the required class path for the enhancement task. In a production environment, this will be composed of jars, of course. --> <path id="db4o.enhance.path"> <pathelement path="${basedir}" /> <fileset dir="lib"> <include name="**/*.jar"/> </fileset> </path> <!-- Define enhancement task. --> <taskdef name="db4o-enhance" classname="com.db4o.instrumentation.ant.Db4oFileEnhancerAntTask" classpathref="db4o.enhance.path" loaderref="db4o.enhance.loader" /> <typedef name="native-query" classname="com.db4o.nativequery.main.NQAntClassEditFactory" classpathref="db4o.enhance.path" loaderref="db4o.enhance.loader" /> <target name="buildall"> <!-- Create enhanced output directory--> <mkdir dir="${basedir}/enhanced-bin" /> <delete dir="${basedir}/enhanced-bin" quiet = "true"> <include name="**/*"/> </delete> <db4o-enhance targetdir="${basedir}/enhanced-bin"> <classpath refid="db4o.enhance.path" /> <!-- Use compiled classes as an input --> <sources dir="${basedir}/bin" /> <!-- Call transparent activation enhancement --> <native-query /> </db4o-enhance> </target> </project>