db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arm...@apache.org
Subject cvs commit: db-ojb/src/schema ojbtest-schema.xml
Date Sat, 28 Feb 2004 10:48:03 GMT
arminw      2004/02/28 02:48:03

  Modified:    .        build.xml
               src/schema ojbtest-schema.xml
  Added:       .        build-ejb-examples.xml
  Removed:     .        build-xdoclet.xml
  Log:
  - rename build file for ejb-examples to prevent confusion
  with xdoclet modul
  
  - fix column declaration
  
  Revision  Changes    Path
  1.115     +4 -4      db-ojb/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/db-ojb/build.xml,v
  retrieving revision 1.114
  retrieving revision 1.115
  diff -u -r1.114 -r1.115
  --- build.xml	25 Feb 2004 01:12:41 -0000	1.114
  +++ build.xml	28 Feb 2004 10:48:03 -0000	1.115
  @@ -1289,17 +1289,17 @@
       <target name="ejb-examples"
               description="Generate the sample session bean ejb-app jar">
           <ant dir="."
  -             antfile="${basedir}/build-xdoclet.xml"
  +             antfile="${basedir}/build-ejb-examples.xml"
                target="jar-beans"/>
           <ant dir="."
  -             antfile="${basedir}/build-xdoclet.xml"
  +             antfile="${basedir}/build-ejb-examples.xml"
                target="jar-client"/>
       </target>
   
       <target name="prepare-jboss"
               description="Copy jboss mbeans to code base">
           <ant dir="."
  -             antfile="${basedir}/build-xdoclet.xml"
  +             antfile="${basedir}/build-ejb-examples.xml"
                target="prepare-jboss"/>
       </target>
   
  
  
  
  1.1                  db-ojb/build-ejb-examples.xml
  
  Index: build-ejb-examples.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!-- OJB ant build script for xdoclet use -->
  <project name="OJB XDoclet" default="jar-beans" basedir=".">
  
      <!-- Allow any user specific values to override the defaults -->
      <property file="build.properties"/>
      <property file="${user.home}/build.properties" />
  
      <property name="java.src.dir" value="${src.dir}/ejb"/>
      <property name="generated.src.dir" value="${build.dir}/srcejb/generated"/>
      <property name="beans.src.dir" value="${build.dir}/srcejb/beans"/>
      <property name="client.src.dir" value="${build.dir}/srcejb/client"/>
      <property name="generated.descriptor.dir" value="${build.dir}/srcejb"/>
      <property name="generated.ejb.classes.dir" value="${build.dir}/classesejb/bean"/>
      <property name="generated.ejb.classes.dir.client" value="${build.dir}/classesejb/client"/>
      <property name="jar.name.beans" value="${ojb-filename-prefix}-beans.jar"/>
      <property name="jar.name.client" value="${ojb-filename-prefix}-client.jar"/>
      <property name="jar.name.ejb.app" value="${ojb-filename-prefix}-ejb-app.jar"/>
      <property name="jar.name.junit" value="${ojb-filename-prefix}-junit.jar"/>
      <property name="jar.name.app" value="${ojb-filename-prefix}.jar"/>
      <property name="jar.dir" value="${dist}"/>
  
      <path id="ojb.classpath">
          <pathelement path="${build.dest}"/>
          <pathelement path="${build.desttest}"/>
          <fileset dir="${lib}">
              <include name="**/*.jar"/>
              <include name="**/*.zip"/>
          </fileset>
      </path>
  
      <target name="classes-exist">
          <available file="${build.dest}/org" property="build.classes.exist"/>
      </target>
      <target name="check" unless="build.classes.exist" depends="classes-exist">
          <fail message="Run target 'main-opt' before run current target"/>
      </target>
  
      <!-- =================================================================== -->
  	<!-- run xdoclet                                                         -->
  	<!-- =================================================================== -->
  	<target name="xdoclet" depends="check">
  		<taskdef
  				name="ejbdoclet"
  				classname="xdoclet.modules.ejb.EjbDocletTask">
  			<classpath refid="ojb.classpath"/>
  		</taskdef>
  
          <delete dir="${generated.src.dir}"/>
  		<mkdir dir="${generated.src.dir}"/>
  
  		<ejbdoclet
  			destdir="${generated.src.dir}"
  			excludedtags="@version,@author"
              addedtags="@xdoclet-generated at ${TODAY}"
  			ejbspec="2.0"
          >
  
  			<fileset dir="${java.src.dir}">
                  <include name="**/Bean*.java" />
  				<include name="**/*Bean.java" />
                  <include name="**/*BeanImpl.java" />
  				<include name="**/*BO.java" />
  			</fileset>
  			<!-- session/-->
  			<!-- dataobject/ -->
  			<remoteinterface/>
  			<localinterface/>
  			<homeinterface/>
  			<localhomeinterface/>
  			<!-- entitycmp pattern="{0}BeanImpl"/ -->
  			<deploymentdescriptor destdir="${generated.descriptor.dir}"/>
  			<jboss version="3.0"
  					xmlencoding="UTF-8"
  					typemapping="Hypersonic SQL"
  					datasource="java:/DefaultDS"
  					destdir="${generated.descriptor.dir}"/>
  		</ejbdoclet>
  	</target>
  
  	<!-- =================================================================== -->
  	<!-- Compiles the source directory and copy all xml                      -->
  	<!-- files in src to classes.dir                                         -->
  	<!-- =================================================================== -->
  	<target name="compile_beans" depends="xdoclet">
  		<delete dir="${generated.ejb.classes.dir}"/>
  		<mkdir dir="${generated.ejb.classes.dir}"/>
  		<mkdir dir="${generated.ejb.classes.dir}/META-INF"/>
  
          <copy  todir="${beans.src.dir}">
  			<fileset dir="${java.src.dir}">
                  <include name="**/Bean*.java" />
  				<include name="**/*Bean.java" />
                  <include name="**/*BeanImpl.java" />
  				<include name="**/*VO.java" />
  			</fileset>
  		</copy>
  
  		<javac srcdir="${generated.src.dir}; ${beans.src.dir}"
  			destdir="${generated.ejb.classes.dir}"
  			debug="${debug}"
  			optimize="${optimize}"
  			deprecation="${deprecation}">
  			<classpath refid="ojb.classpath"/>
  		</javac>
  
  		<!-- copy  todir="${generated.ejb.classes.dir}/META-INF">
  			<fileset dir="${generated.descriptor.dir}" includes="**/*.xml"/>
  		</copy -->
  
          <!-- delete>
              <fileset dir="${generated.src.dir}">
                  <include name="**/*Bean.java" />
                  <include name="**/*BO.java" />
                  <include name="**/*BeanImpl.java" />
              </fileset>
  		</delete -->
  	</target>
  
      <!-- =================================================================== -->
  	<!-- jboss mbeans, workaround till JCA works                             -->
  	<!-- =================================================================== -->
      <target name="prepare-jboss">
          <copy  todir="${build.src}">
  			<fileset dir="${src.dir}/connector/main">
                  <include name="**/ODMGFactory*.java" />
  				<include name="**/PBFactory*.java" />
  			</fileset>
  		</copy>
      </target>
  
  
  	<!-- =================================================================== -->
  	<!-- Build deployable jar of the generated files                         -->
  	<!-- =================================================================== -->
      <target name="jar-beans" depends="compile_beans">
          <jar jarfile="${jar.dir}/${jar.name.beans}"
              basedir="${generated.ejb.classes.dir}" >
              <metainf dir="${generated.descriptor.dir}">
                  <include name="**/*.xml" />
              </metainf>
              <manifest>
                  <!-- attribute name="classpath" value="db-ojb-1.0.rc2.jar ${classpath.attributes}"/
-->
              </manifest>
              <!-- fileset dir="${jar.dir}"
                  includes="${jar.name.junit}"
              / -->
          </jar>
      </target>
  
      <!-- =================================================================== -->
  	<!-- Build the client jar                                                -->
  	<!-- =================================================================== -->
      <target name="jar-client" depends="check"
              description="Build the client jar">
          <copy  todir="${client.src.dir}">
  			<fileset dir="${java.src.dir}"
                  excludes="**/*Bean.class,
  			 		   **/*VO.class,
  			 		   **/*BeanImpl.class,
  			 		   **/*.xml,
  			 		   **/*.properties">
  			</fileset>
  		</copy>
  
          <javac srcdir="${client.src.dir}; ${generated.src.dir}"
  			destdir="${generated.ejb.classes.dir}"
  			debug="${debug}"
  			optimize="${optimize}"
  			deprecation="${deprecation}">
  			<classpath refid="ojb.classpath"/>
  		</javac>
  
          <jar jarfile="${jar.dir}/${jar.name.client}"
  			 basedir="${generated.ejb.classes.dir}"
  			 excludes="**/*Bean.class,
  			 		   **/*VO.class,
  			 		   **/*BeanImpl.class,
  			 		   **/*.xml,
  			 		   **/*.properties">
          </jar>
  
      </target>
  
  </project>
  
  
  
  1.65      +1 -1      db-ojb/src/schema/ojbtest-schema.xml
  
  Index: ojbtest-schema.xml
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/schema/ojbtest-schema.xml,v
  retrieving revision 1.64
  retrieving revision 1.65
  diff -u -r1.64 -r1.65
  --- ojbtest-schema.xml	19 Feb 2004 01:39:40 -0000	1.64
  +++ ojbtest-schema.xml	28 Feb 2004 10:48:03 -0000	1.65
  @@ -615,7 +615,7 @@
       <table name="EJB_ARTICLE">
           <column name="ARTICLE_ID" required="true" primaryKey="true" type="INTEGER"/>
           <column name="NAME" type="VARCHAR" size="80"/>
  -        <column name="PRICE" type="DECIMAL"/>
  +        <column name="PRICE" type="DECIMAL" size="15,2"/>
           <column name="DESCRIPTION" type="VARCHAR" size="255"/>
           <column name="CATEGORY_ID" required="false" type="INTEGER"/>
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Mime
View raw message