Class: atg.appassembly.ant.PackEarFileTask
Description
This Ant task takes an EAR file in exploded (open-directory) format, and packs it into the archive-file format specified by the J2EE standard.
Required Task Parameters
Attribute | Description |
---|---|
| Specifies the staging directory containing the unpacked application. |
| Specifies the filename for the packed EAR file. |
Example
To use PackEarFileTask
in an Ant build file, you must first declare it, using the taskdef
element:
<taskdef name="pack-ear"
classname="atg.appassembly.ant.PackEarFileTask"
classpath="C:/ATG/ATG10.1/home/lib/assembler.jar">
This example is a target that uses CreateUnpackedEarTask
to create the application in unpacked format, and then uses the PackEarFileTask
to pack the application in an EAR file:
<target name="create-quincy-ear"> <-- It's a good idea to delete any old directories before assembling... --> <delete dir="QuincyFundsEar"/> <assemble-jar dynamoRoot="C:/ATG/ATG10.1" dynamoModules="DSSJ2EEDemo,DafEar.Admin" destinationFile="QuincyFundsEar" overwrite="true" /> <pack-ear sourceFile = "QuincyFundsEar" destinationFile = "Quincy.ear" /> <-- Delete the open directory, and keep the packed EAR file. --> <delete dir="QuincyFundsEar"/> </target>