Introduction
Check the official documentation first on the ANT Site.
You can find here an article about security in borland enterprise server written by Krishnan Subramanian that i have formated
More Java articles ? Check my website !You can find here an article about security in borland enterprise server written by Krishnan Subramanian that i have formated
More Java articles ? Check my website !It is very easy to solve this:
The best is to put the DTDs on a local web site (on a LAN)
and to add dtd node that redirect the DTD.
With a sample it is better: the two <dtd>s tells where to
find official DTD for ejbjar.xml and the vendor dtd.
<ejbjar srcdir="${build.dir}"
basejarname="${ant.project.name}"
descriptordir="${rsc.dir}/${ant.project.name}/J2EE">
<borland destdir="lib"
verify="off" generateclient="on" debug="on" version="5">
<classpath refid="classpath" />
</borland>
<dtd publicid="-//Sun
Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
location= "http://mylocalserver/dtds/ejb-jar_2_0.dtd" />
<dtd
publicid="-//Borland
Software Corporation//DTD Enterprise JavaBeans 2.0//EN"
location=
"http://mylocalserver/dtds/ejb-jar_2_0-borland.dtd" />
<include
name="ejb-jar.xml"/>
<support
dir="${build.dir}">
<include name="com\mycompangny\a\b\c\MyClass.class"/>
</support>
</ejbjar>
vbj com.borland.ejb.pm.EntityBeanCodeGen
Arguments:
-Directory with compiled bean code
-Abstract bean class name
-Name(s) of home interface(s)
Output:
-Concrete bean class source code (e.g. RoomBean_PM)
Typically this command is launched by JBuilder(X). If you need them add a <java> task in your build.xml
New ! 5 March 2004 David Leroy, a cool guy, has written two new classes to handle the _PM generation. He has created two new classes to accommodate my needs: EjbCMPJar.java, which extends EjbJar and BorlandCMPDeploymentTool, which extends your BorlandDeploymentTool. The new task is called "ejbcmpjar" and the new subtask is called "borlandcmp". Here is a snippet of the buildfile:
<taskdef name="ejbcmpjar"
classname="org.apache.tools.ant.taskdefs.optional.ejb.EjbCMPJar" />
<target name="generate Borland" depends = "compile Borland, package"
description="Generate EJBs for Borland Enterprise Server">
<mkdir dir="${dir.ejbs}" />
<mkdir dir="${dir.ejbs}/cmp" />
<ejbcmpjar descriptordir="${dir.edd}"
srcdir="${dir.classes}"
naming="directory"
dependency="none"
manifest="${manifest}">
<classpath>
<path refid="classpath.deploy" />
</classpath>
<include name="**/ejb-jar.xml" />
( ... omitted <dtd> elemements ...)
<borlandcmp destdir="${dir.ejbs}"
cmpdir="${dir.ejbs}/cmp"
version="5"
suffix=".jar"
verify="false"
</borlandcmp>
</ejbcmpjar>
</target>
Back to moussaud.org