public class PearPackagingAntTask
extends org.apache.tools.ant.Task
<!-- define the classpath settings for the pear packaging task.
uimaj-pear-task.jar and uima-core.jar is needed -->
<path id="pearTask.classpath">
<fileset dir="/home/apache-uima/lib/" includes="uimaj-pear-task.jar"/>
<fileset dir="/home/apache-uima/lib/" includes="uima-core.jar"/>
</path>
<!-- pear packaging sample target -->
<target name="pearPackagingSample">
<!-- Define pear packaging task -->
<taskdef name="packagePear"
classname="org.apache.uima.pear.tools.PearPackagingAntTask"
classpathref="pearTask.classpath"/>
<!-- Sample pear packaging -->
<packagePear componentID="SampleAnnotator"
mainComponentDesc="desc/mainComponentDesc.xml"
classpath="$main_root/pearClasspahtEntry;$main_root/anotherPearClasspahtEntry"
datapath="$main_root/resources"
mainComponentDir="/home/user/workspace/SampeAnntotator"
targetDir="/home/user/pearArchive">
<envVar name="ENV_VAR_NO1" value="value1"/>
<envVar name="ENV_VAR_NO2" value="value2"/>
</packagePear>
</target>
| Constructor and Description |
|---|
PearPackagingAntTask() |
| Modifier and Type | Method and Description |
|---|---|
void |
addEnvVar(org.apache.tools.ant.types.Parameter envVar)
add environment variable for the pear component
|
void |
execute() |
void |
setClasspath(String classpath)
set classpath for the pear component.
|
void |
setComponentID(String componentID)
set component ID for the pear component
|
void |
setDatapath(String datapath)
the datapath setting for the pear component
|
void |
setMainComponentDesc(String mainComponentDesc)
the main component descriptor for the pear component
|
void |
setMainComponentDir(String mainComponentDir)
the main component directory for the pear data
|
void |
setTargetDir(String targetDir)
the target directory for the output
|
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskTypepublic void execute()
throws org.apache.tools.ant.BuildException
execute in class org.apache.tools.ant.Taskorg.apache.tools.ant.BuildExceptionpublic void addEnvVar(org.apache.tools.ant.types.Parameter envVar)
envVar - environment variable settingpublic void setClasspath(String classpath)
classpath - the classpath to setpublic void setComponentID(String componentID)
componentID - the componentID to setpublic void setDatapath(String datapath)
datapath - the datapath to setpublic void setMainComponentDesc(String mainComponentDesc)
mainComponentDesc - the mainComponentDesc to setpublic void setMainComponentDir(String mainComponentDir)
mainComponentDir - the mainComponentDir to setpublic void setTargetDir(String targetDir)
targetDir - the targetDir to setCopyright © 2006–2025 The Apache Software Foundation. All rights reserved.