Fixed guy's

----- Original Message -----
From: "Mark Ayad" <[EMAIL PROTECTED]>
To: "Turbine Torque Users List" <[EMAIL PROTECTED]>
Sent: Monday, August 19, 2002 1:19 AM
Subject: Re: The template path needs to be defined (on windows)


> I have altered the build-torque.xml file to:- however no luck.
>
> I have also searched the cvs for an alternate file.
>
> Can anyone supply a patched build-torque.xml file ?
>
> Best Regards Mark
>
>  <target name="check-use-classpath">
>     <condition property="torque.internal.useClasspath">
>       <equals arg1="${useClasspath}" arg2="true"/>
>     </condition>
>   </target>
>
>   <target
>     name="sql-template"
>     depends="check-use-classpath" unless="torque.internal.useClasspath">
>
>     <echo message="using template path ${templatePath}"/>
>
>     <torque-sql
>       contextProperties="${build.properties}"
>       controlTemplate="${SQLControlTemplate}"
>       outputDirectory="${torque.home}/${outputDirectory}/sql"
>       templatePath="${templatePath}"
>       basePathToDbProps="sql/base/"
>       sqldbmap="${torque.home}/${outputDirectory}/sql/sqldb.map"
>       outputFile="report.${project}.sql.generation"
>       targetDatabase="${database}"
>       idTableXMLFile="${idTableXMLFile}">
>       <fileset dir="${torque.home}/${schemaDirectory}">
>         <include name="*-schema.xml"/>
>       </fileset>
>     </torque-sql>
>   </target>
>
>
> ----- Original Message -----
> From: "Mark Ayad" <[EMAIL PROTECTED]>
> To: "Turbine Torque Users List" <[EMAIL PROTECTED]>;
> <[EMAIL PROTECTED]>
> Sent: Monday, August 19, 2002 12:27 AM
> Subject: Re: The template path needs to be defined (on windows)
>
>
> > Stephen,
> >
> > I had a look at the list, but I wasn't sure of the suggested fix, is the
> > solution just to patch the build-torque.xml file?
> >
> > or is it a complete soure build ?
> >
> > Thanks for the support.
> >
> > Mark
> >
> > ----- Original Message -----
> > From: "Stephen Haberman" <[EMAIL PROTECTED]>
> > To: "'Turbine Torque Users List'"
<[EMAIL PROTECTED]>
> > Sent: Monday, August 19, 2002 12:10 AM
> > Subject: RE: The template path needs to be defined (on windows)
> >
> >
> > > Yeah, this is a known issue that will be fixed in the next beta. I
> > > posted a temporary patch for this two weeks ago or so. It might be on
> > > the dev list, so my initial reaction is that it's on the user list.
> > >
> > > - Stephen
> > >
> > > > -----Original Message-----
> > > > From: Mark Ayad [mailto:[EMAIL PROTECTED]]
> > > > Sent: Sunday, August 18, 2002 4:16 PM
> > > > To: [EMAIL PROTECTED]
> > > > Subject: The template path needs to be defined (on windows)
> > > >
> > > > -------------------------------------------
> > > > Platform: windows 2000
> > > > Ant Version: Ant version 1.4.1
> > > > Torque: torque-3.0-b3
> > > > -------------------------------------------
> > > >
> > > > I wanted to run a quick test, so without changing anything I ran the
> > > command:-
> > > >
> > > > ant -f build-torque.xml
> > > >
> > > > and I got the following error:-
> > > >
> > > > C:\torque-3.0-b3>ant -f build-torque.xml
> > > > Buildfile: build-torque.xml
> > > >
> > > > main:
> > > >
> > > > sql:
> > > >      [echo] +------------------------------------------+
> > > >      [echo] |                                          |
> > > >      [echo] | Generating SQL for YOUR Turbine project! |
> > > >      [echo] | Woo hoo!                                 |
> > > >      [echo] |                                          |
> > > >      [echo] +------------------------------------------+
> > > >
> > > > sql-classpath:
> > > >      [echo] using classpath
> > > > [torque-sql] Using contextProperties file:
> > > C:\torque-3.0-b3\build.properties
> > > >
> > > > BUILD FAILED
> > > >
> > > > C:\torque-3.0-b3\build-torque.xml:108: The template path needs to be
> > > defined if you
> > > > are not using the classpath for locating templates!
> > > >
> > > > Total time: 1 second
> > > >
> > > > As you can see its complaining about the template path ):
> > > >
> > > > I've checked that useClasspath=false, and in the build.properties
file
> > > it says:-
> > > >
> > > >
# -------------------------------------------------------------------
> > > > # You should NOT have to edit anything below here.
> > > >
# -------------------------------------------------------------------
> > > >
> > > > where the template path is defined:
> > > >
> > > > As a way round I wrote an env.bat:-
> > > >
> > > > @echo off
> > > > set CLASSPATH=
> > > > set
> > > CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\commons-collections-2.0.jar
> > > > set
> > > CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\commons-configuration-1.0-
> > > > dev.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\commons-lang-1.0-dev-
> > > > 20020716.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\commons-pool-1.0.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\jcs-1.0-dev.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\jdbc-2.0.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\log4j-1.1.3.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\stratum-1.0-b2.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\torque-3.0-b3.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\velocity-1.3.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\village-1.5.3.jar
> > > > set CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\xercesImpl-2.0.2.jar
> > > > set
CLASSPATH=%CLASSPATH%;C:\torque-3.0-b3\lib\xmlParserAPIs-2.0.2.jar
> > > > set CLASSPATH=%CLASSPATH%;.;
> > > >
> > > > changed useClasspath=true
> > > >
> > > > and tried:-
> > > >
> > > > C:\torque-3.0-b3>ant -f build-torque.xml
> > > >
> > > > It worked OK
> > > >
> > > >
> > >
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > <mailto:[EMAIL PROTECTED]>
> > > For additional commands, e-mail:
> > <mailto:[EMAIL PROTECTED]>
> > >
> > >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> >
> >
>
>
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
>
>
<project name="Torque" default="main" basedir=".">

  <property name="torque.home" value="."/>
  <property name="build.properties" value="build.properties"/>
  <property file="${build.properties}"/>
  <property name="lib.dir" value="lib"/>
  <property name="idTableXMLFile" value=""/>

  <!-- Build classpath -->
  <path id="torque-classpath">
    <fileset dir="${lib.dir}">
      <include name="**/*.jar"/>
    </fileset>
  </path>

  <!--
    Do forward declarations of all of our tasks to 
    centralize them and clean up the targets.
  -->
  <taskdef
    name="torque-data-model"
    classpathref="torque-classpath"
    classname="org.apache.torque.task.TorqueDataModelTask"/>
  <taskdef
    name="torque-data-dump"
    classpathref="torque-classpath"
    classname="org.apache.torque.task.TorqueDataDumpTask"/>
  <taskdef
    name="torque-data-sql"
    classpathref="torque-classpath"
    classname="org.apache.torque.task.TorqueDataSQLTask"/>
  <taskdef
    name="torque-doc"
    classpathref="torque-classpath"
    classname="org.apache.torque.task.TorqueDocumentationTask"/>
  <taskdef
    name="torque-jdbc-transform"
    classpathref="torque-classpath"
    classname="org.apache.torque.task.TorqueJDBCTransformTask"/>
  <taskdef
    name="torque-sql"
    classpathref="torque-classpath"
    classname="org.apache.torque.task.TorqueSQLTask"/>
  <taskdef
    name="torque-sql-exec"
    classpathref="torque-classpath"
    classname="org.apache.torque.task.TorqueSQLExec"/>
  <taskdef
    name="torque-sql-transform"
    classpathref="torque-classpath"
    classname="org.apache.torque.task.TorqueSQLTransformTask"/>

  <!-- ================================================================ -->
  <!-- M A I N  T A R G E T                                             -->
  <!-- ================================================================ -->
  <!-- This default target will run all the targets that generate       -->
  <!-- source. You will probably only run this target once then         -->
  <!-- call individual targets as necessary to update your sources      -->
  <!-- when you change your XML schema.                                 -->
  <!-- ================================================================ -->

  <target
    name="main"
    description="==> generates sql + om classes">

    <antcall target="sql"/>
    <antcall target="om"/>
  </target>

	<!-- ================================================================ -->
  <!-- C H E C K  U S E C L A S S P A T H                               -->
  <!-- ================================================================ -->
  <!-- Temporary hack around the propertiesUtil bug. Should             -->
  <!-- be fixed soon.                                                   -->
  <!-- ================================================================ -->

  <target name="check-use-classpath">
    <condition property="torque.internal.useClasspath">
      <equals arg1="${torque.useClasspath}" arg2="true"/>
    </condition>
  </target>

  <!-- ================================================================ -->
  <!-- G E N E R A T E  P R O J E C T  S Q L                            -->
  <!-- ================================================================ -->
  <!-- Generate the SQL for your project, these are in addition         -->
  <!-- to the base Turbine tables! The tables you require for your      -->
  <!-- project should be specified in project-schema.xml.               -->
  <!-- ================================================================ -->


  <target
    name="sql"
    depends="check-use-classpath"
    description="==> generates the SQL for your project">


    <echo message="+------------------------------------------+"/>
    <echo message="|                                          |"/>
    <echo message="| Generating SQL for YOUR Turbine project! |"/>
    <echo message="| Woo hoo!                                 |"/>
    <echo message="|                                          |"/>
    <echo message="+------------------------------------------+"/>

    <antcall target="sql-classpath"/>
    <antcall target="sql-template"/>
  </target>


  <target name="sql-classpath" if="torque.internal.useClasspath">
    

    <echo message="using classpath"/>

    <torque-sql
      contextProperties="${build.properties}"
      controlTemplate="${SQLControlTemplate}"
      outputDirectory="${torque.home}/${outputDirectory}/sql"
      useClasspath="${useClasspath}"
      basePathToDbProps="sql/base/"
      sqldbmap="${torque.home}/${outputDirectory}/sql/sqldb.map"
      outputFile="report.${project}.sql.generation"
      targetDatabase="${database}"
      idTableXMLFile="${idTableXMLFile}">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
      </fileset>
    </torque-sql>
  </target>


  <target name="sql-template" unless="torque.internal.useClasspath">
    
    <echo message="using template path ${templatePath}"/>

    <torque-sql
      contextProperties="${build.properties}"
      controlTemplate="${SQLControlTemplate}"
      outputDirectory="${torque.home}/${outputDirectory}/sql"
      templatePath="${templatePath}"
      basePathToDbProps="sql/base/"
      sqldbmap="${torque.home}/${outputDirectory}/sql/sqldb.map"
      outputFile="report.${project}.sql.generation"
      targetDatabase="${database}"
      idTableXMLFile="${idTableXMLFile}">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
      </fileset>
    </torque-sql>
  </target>

  <!-- ================================================================ -->
  <!-- G E N E R A T E   D O C S                                        -->
  <!-- ================================================================ -->

  <target
    name="doc"
    description="==> generates documentation for your datamodel">

    <echo message="+------------------------------------------+"/>
    <echo message="|                                          |"/>
    <echo message="| Generating docs for YOUR datamodel!      |"/>
    <echo message="| Woo hoo!                                 |"/>
    <echo message="|                                          |"/>
    <echo message="+------------------------------------------+"/>

    <torque-doc
      contextProperties="${build.properties}"
      controlTemplate="${DocControlTemplate}"
      outputDirectory="${torque.home}/${outputDirectory}/doc"
      useClasspath="${useClasspath}"
      outputFormat="${documentationFormat}"
      templatePath="${templatePath}"
      sqldbmap="${torque.home}/${outputDirectory}/sql/sqldb.map"
      outputFile="report.${project}.doc.generation">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
      </fileset>
    </torque-doc>
  </target>

  <!-- ================================================================ -->
  <!-- C R E A T E  T A R G E T  D A T A B A S E                        -->
  <!-- ================================================================ -->
  <!-- Create the target database by executing a generated script       -->
  <!-- that is capable of performing the task.                          -->
  <!-- ================================================================ -->

  <target
    name="create-db"
    unless="database.manual.creation"
    description="==> generates the target database">

    <torque-data-model
      controlTemplate="sql/db-init/Control.vm"
      outputDirectory="${torque.home}/${outputDirectory}/sql"
      useClasspath="${useClasspath}"
      targetDatabase="${database}"
      templatePath="${templatePath}"
      outputFile="create-db.sql">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
      </fileset>
    </torque-data-model>

    <echo>
      Executing the create-db.sql script ...
    </echo>

    <sql
      driver="${databaseDriver}"
      url="${createDatabaseUrl}"
      userid="${databaseUser}"
      password="${databasePassword}"
      src="${torque.home}/${outputDirectory}/sql/create-db.sql"
      autocommit="true"
      onerror="continue">
      <classpath refid="torque-classpath"/>
    </sql>
  </target>

  <!-- ================================================================ -->
  <!-- I N S E R T  S I N G L E  S Q L  F I L E S                       -->
  <!-- ================================================================ -->

  <target
    name="insert-sql">

    <torque-sql-exec
      driver="${databaseDriver}"
      url="${buildDatabaseUrl}"
      userid="${databaseUser}"
      password="${databasePassword}"
      autocommit="true"
      onerror="continue"
      sqldbmap="${torque.home}/${outputDirectory}/sql/sqldb.map"
      srcDir="${torque.home}/${outputDirectory}/sql">
      <classpath refid="torque-classpath"/>
    </torque-sql-exec>
  </target>

  <!-- ================================================================ -->
  <!-- J D B C  TO  X M L                                               -->
  <!-- ================================================================ -->

  <target
    name="jdbc"
    description="==> jdbc to xml">

    <echo message="+-----------------------------------------------+"/>
    <echo message="|                                               |"/>
    <echo message="| Generating XML from JDBC connection !         |"/>
    <echo message="| Woo hoo!                                      |"/>
    <echo message="|                                               |"/>
    <echo message="+-----------------------------------------------+"/>
    <echo message=" taking build.properties from: ${build.properties}"/>

    <torque-jdbc-transform
      dbUrl="${databaseUrl}"
      dbDriver="${databaseDriver}"
      dbUser="${databaseUser}"
      dbPassword="${databasePassword}"
      dbSchema="${databaseSchema}"
      outputFile="${torque.home}/${outputDirectory}/schema.xml"
      sameJavaName="${sameJavaName}"
    />
  </target>

  <!-- ================================================================ -->
  <!-- Generate SQL from XML data file                                  -->
  <!-- ================================================================ -->

  <target
    name="datasql"
    description="==> generates sql from data xml">

    <echo message="+-----------------------------------------------+"/>
    <echo message="|                                               |"/>
    <echo message="| Generating SQL from data XML !                |"/>
    <echo message="| Woo hoo!                                      |"/>
    <echo message="|                                               |"/>
    <echo message="+-----------------------------------------------+"/>
    <echo message=" taking build.properties from: ${build.properties}"/>

    <torque-data-sql
      contextProperties="${build.properties}"
      controlTemplate="${DataSQLControlTemplate}"
      outputDirectory="${torque.home}/${outputDirectory}"
      useClasspath="${useClasspath}"
      templatePath="${templatePath}"
      outputFile="${project}-data.sql"
      xmlFile="${torque.home}/${schemaDirectory}/${project}-schema.xml"
      dataXmlFile="${torque.home}/${schemaDirectory}/${project}-data.xml"
      dataDTD="${torque.home}/${schemaDirectory}/${project}-data.dtd"
      targetDatabase="${database}"
      sqldbmap="${basedir}/${outputDirectory}/sql/sqldb.map"
    />
  </target>

  <!-- ================================================================ -->
  <!-- G E N E R A T E   I D   B R O K E R   I N I T   S Q L            -->
  <!-- ================================================================ -->

  <target
    name="id-table-init-sql">

    <echo message="+------------------------------------------+"/>
    <echo message="|                                          |"/>
    <echo message="| Generating initialization SQL            |"/>
    <echo message="| for ID Broker system!                    |"/>
    <echo message="|                                          |"/>
    <echo message="+------------------------------------------+"/>

    <torque-sql
      contextProperties="${build.properties}"
      controlTemplate="${idTableControlTemplate}"
      suffix="-idtable-init"
      sqldbmap="${torque.home}/${outputDirectory}/sql/sqldb.map"
      outputDirectory="${torque.home}/${outputDirectory}/sql"
      useClasspath="${useClasspath}"
      templatePath="${templatePath}"
      outputFile="${database}-id-table-init.sql"
      targetDatabase="${database}">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
        <exclude name="id-table-schema.xml"/>
      </fileset>
    </torque-sql>
  </target>

  <!-- ================================================================ -->
  <!-- Dump data from database into xml file                            -->
  <!-- ================================================================ -->

  <target
    name="datadump"
    description="==> dump data from database into xml file">

    <echo message="+-----------------------------------------------+"/>
    <echo message="|                                               |"/>
    <echo message="| Dumping the data from database into XML       |"/>
    <echo message="| Woo hoo!                                      |"/>
    <echo message="|                                               |"/>
    <echo message="+-----------------------------------------------+"/>
    <echo message=" taking build.properties from: ${build.properties}"/>

    <torque-data-dump
      contextProperties="${build.properties}"
      controlTemplate="${DataDumpControlTemplate}"
      outputDirectory="${torque.home}/${outputDirectory}"
      useClasspath="${useClasspath}"
      templatePath="${templatePath}"
      outputFile="report.${project}.datadump.generation"
      xmlFile="${torque.home}/${schemaDirectory}/${project}-schema.xml"
      databaseDriver="${databaseDriver}"
      databaseUrl="${databaseUrl}"
      databaseUser="${databaseUser}"
      databasePassword="${databasePassword}"
      databaseName="${databaseName}"
    />
  </target>

  <!-- ================================================================ -->
  <!-- G E N E R A T E  P R O J E C T  D A T A  D T D                   -->
  <!-- ================================================================ -->
  <!-- Generate the DATA DTD for your project                           -->
  <!-- ================================================================ -->

  <target
    name="datadtd"
    description="==> generates the DATA DTD for your project">

    <echo message="+-----------------------------------------------+"/>
    <echo message="|                                               |"/>
    <echo message="| Generating Data DTD for YOUR Turbine project! |"/>
    <echo message="| Woo hoo!                                      |"/>
    <echo message="|                                               |"/>
    <echo message="+-----------------------------------------------+"/>

    <torque-data-model
      contextProperties="${build.properties}"
      controlTemplate="${DataDTDControlTemplate}"
      outputDirectory="${torque.home}/${outputDirectory}"
      useClasspath="${useClasspath}"
      templatePath="${templatePath}"
      outputFile="report.${project}.datadtd.generation"
      xmlFile="${torque.home}/${schemaDirectory}/${project}-schema.xml"
    />
  </target>

  <!-- ================================================================ -->
  <!-- G E N E R A T E  P R O J E C T  P E E R  B A S E D  O M          -->
  <!-- ================================================================ -->
  <!-- Generate the Peer-based object model for your project.           -->
  <!-- These are in addition to the base Turbine OM!                    -->
  <!-- ================================================================ -->

  
  <target
    name="om"
    depends="check-use-classpath"
    description="==> generates the Peer-based object model for your project">

    <echo message="+------------------------------------------+"/>
    <echo message="|                                          |"/>
    <echo message="| Generating Peer-based Object Model for   |"/>
    <echo message="| YOUR Turbine project! Woo hoo!           |"/>
    <echo message="|                                          |"/>
    <echo message="+------------------------------------------+"/>

    <antcall target="om-classpath"/>
    <antcall target="om-template"/>
  </target>

  
  <target name="om-classpath" if="torque.internal.useClasspath">
    

    <echo message="using classpath"/>

    <torque-data-model
      contextProperties="${build.properties}"
      controlTemplate="${OMControlTemplate}"
      outputDirectory="${torque.home}/${outputDirectory}/java"
      useClasspath="${useClasspath}"
      outputFile="report.${project}.om.generation"
      targetPackage="${targetPackage}"
      targetDatabase="${database}">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
        <exclude name="id-table-schema.xml"/>
      </fileset>
    </torque-data-model>
  </target>

  <target name="om-template" unless="torque.internal.useClasspath">
    
    <echo message="using template path ${templatePath}"/>

    <torque-data-model
      contextProperties="${build.properties}"
      controlTemplate="${OMControlTemplate}"
      outputDirectory="${torque.home}/${outputDirectory}/java"
      templatePath="${templatePath}"
      outputFile="report.${project}.om.generation"
      targetPackage="${targetPackage}"
      targetDatabase="${database}">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
        <exclude name="id-table-schema.xml"/>
      </fileset>
    </torque-data-model>
  </target>

  <!-- =================================================================== -->
  <!-- C O M P I L E  O M                                                  -->
  <!-- =================================================================== -->

  <target
    name="compile"
    description="==> compiles the OM classes">

    <!--
      This should be moved to the top of the file, and
      the values should come from the build.properties file.
    -->

    <property name="src.dir" value="${outputDirectory}/java"/>
    <property name="build.dest" value="bin/classes"/>
    <property name="debug" value="on"/>
    <property name="deprecation" value="off"/>
    <property name="optimize" value="off"/>

    <mkdir dir="${build.dest}"/>

    <javac srcdir="${src.dir}"
      destdir="${build.dest}"
      debug="${debug}"
      deprecation="${deprecation}"
      optimize="${optimize}">
      <classpath refid="torque-classpath"/>
    </javac>
  </target>

  <!-- =================================================================== -->
  <!-- S Q L  T O  X M L                                                   -->
  <!-- =================================================================== -->
  <!-- Create an xml schema from an sql schema.                            -->
  <!--                                                                     -->
  <!--  inputFile: The input sql file. This must be valid sql file but     -->
  <!--             it not not be in any specific format.                   -->
  <!-- outputFile: The file where the xml schema will be written           -->
  <!-- =================================================================== -->

  <target
    name="sql2xml"
    description="==> creates an xml schema from an sql schema">

    <torque-sql-transform
      inputFile="schema/schema.sql"
      outputFile="schema/schema.xml"
    />
  </target>

  <!-- ================================================================== -->
  <!-- J A V A D O C                                                      -->
  <!-- ================================================================== -->

  <target
    name="javadocs"
    description="==> generates the API documentation">

    <mkdir dir="${torque.home}/${outputDirectory}/javadoc"/>

    <javadoc
      sourcepath="${torque.home}/${outputDirectory}/java"
      packagenames="${targetPackage}.*"
      destdir="${outputDirectory}/javadoc"
      author="true"
      private="true"
      version="true"
      use="true">
      <classpath refid="torque-classpath"/>
    </javadoc>
  </target>

  <!-- =================================================================== -->
  <!-- =================================================================== -->
  <!-- O J B   S T U F F                                                   -->
  <!-- =================================================================== -->
  <!-- =================================================================== -->

  <target
    name="ojb-repository">

    <echo message="+------------------------------------------+"/>
    <echo message="|                                          |"/>
    <echo message="| Generating OJB repository                |"/>
    <echo message="|                                          |"/>
    <echo message="+------------------------------------------+"/>

    <torque-data-model
      contextProperties="${build.properties}"
      controlTemplate="ojb/repository/Control.vm"
      targetPackage="${targetPackage}"
      targetDatabase="${database}"
      outputDirectory="${torque.home}/${outputDirectory}/ojb"
      useClasspath="${useClasspath}"
      templatePath="${templatePath}"
      sqldbmap="${torque.home}/${outputDirectory}/sql/sqldb.map"
      outputFile="report.${project}.ojb.generation">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
      </fileset>
    </torque-data-model>
  </target>

  <target
    name="ojb-model">

    <echo message="+------------------------------------------+"/>
    <echo message="|                                          |"/>
    <echo message="| Generating OJB model                     |"/>
    <echo message="|                                          |"/>
    <echo message="+------------------------------------------+"/>

    <torque-data-model
      contextProperties="${build.properties}"
      controlTemplate="ojb/model/Control.vm"
      targetPackage="${targetPackage}"
      targetDatabase="${database}"
      outputDirectory="${torque.home}/${outputDirectory}/ojb"
      useClasspath="${useClasspath}"
      templatePath="${templatePath}"
      sqldbmap="${torque.home}/${outputDirectory}/sql/sqldb.map"
      outputFile="report.${project}.ojb.generation">
      <fileset dir="${torque.home}/${schemaDirectory}">
        <include name="*-schema.xml"/>
      </fileset>
    </torque-data-model>
  </target>

  <!--
    Deprecated targets with the project- prefix.
  -->
  <target name="project-sql">
    <echo message="The 'project-sql' target is deprecated. Please use the 'sql' target instead."/>
    <antcall target="sql"/>
  </target>
  <target name="project-om">
    <echo message="The 'project-om' target is deprecated. Please use the 'om' target instead."/>
    <antcall target="om"/>
  </target>
  <target name="project-doc">
    <echo message="The 'project-doc' target is deprecated. Please use the 'doc' target instead."/>
    <antcall target="doc"/>
  </target>
  <target name="project-create-db">
    <echo message="The 'project-create-db' target is deprecated. Please use the 'create-db' target instead."/>
    <antcall target="create-db"/>
  </target>
  <target name="project-insert-sql">
    <echo message="The 'project-insert-sql' target is deprecated. Please use the 'insert-sql' target instead."/>
    <antcall target="insert-sql"/>
  </target>
  <target name="project-jdbc">
    <echo message="The 'project-jdbc' target is deprecated. Please use the 'jdbc' target instead."/>
    <antcall target="jdbc"/>
  </target>
  <target name="project-datasql">
    <echo message="The 'project-datasql' target is deprecated. Please use the 'datasql' target instead."/>
    <antcall target="datasql"/>
  </target>
  <target name="project-datadump">
    <echo message="The 'project-datadump' target is deprecated. Please use the 'datadump' target instead."/>
    <antcall target="datadump"/>
  </target>
  <target name="project-datadtd">
    <echo message="The 'project-datadtd' target is deprecated. Please use the 'datadtd' target instead."/>
    <antcall target="datadtd"/>
  </target>
  <target name="project-sql2xml">
    <echo message="The 'project-sql2xml' target is deprecated. Please use the 'sql2xml' target instead."/>
    <antcall target="sql2xml"/>
  </target>
  <target name="project-ojb-repository">
    <echo message="The 'project-ojb-repository' target is deprecated. Please use the 'ojb-repository' target instead."/>
    <antcall target="ojb-repository"/>
  </target>
  <target name="project-ojb-model">
    <echo message="The 'project-obj-model' target is deprecated. Please use the 'ojb-model' target instead."/>
    <antcall target="ojb-model"/>
  </target>

</project>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to