org.apache.tools.ant.taskdefs
Class CallTarget
Call another target in the same project.
<target name="foo">
<antcall target="bar">
<param name="property1" value="aaaaa" />
<param name="foo" value="baz" />
</antcall>
</target>
<target name="bar" depends="init">
<echo message="prop is ${property1} ${foo}" />
</target>
This only works as expected if neither property1 nor foo are
defined in the project itself.
execute , getDescription , getLocation , getOwningTarget , getRuntimeConfigurableWrapper , getTaskName , getTaskType , getWrapper , handleErrorFlush , handleErrorOutput , handleFlush , handleInput , handleOutput , init , isInvalid , log , log , maybeConfigure , perform , reconfigure , setDescription , setLocation , setOwningTarget , setRuntimeConfigurableWrapper , setTaskName , setTaskType |
addConfiguredTarget
public void addConfiguredTarget(Ant.TargetElement t)
Add a target to the list of targets to invoke.
t
- Ant.TargetElement
representing the target.
addPropertyset
public void addPropertyset(PropertySet ps)
Set of properties to pass to the new project.
ps
- the PropertySet
to pass.
addReference
public void addReference(Ant.Reference r)
Reference element identifying a data type to carry
over to the invoked target.
r
- the specified Ant.Reference
.
createParam
public Property createParam()
Create a new Property to pass to the invoked target(s).
execute
public void execute()
throws BuildException
Delegate the work to the ant task instance, after setting it up.
- execute in interface Task
BuildException
- on validation failure or if the target didn't
execute.
handleFlush
public void handleFlush(String output)
- handleFlush in interface Task
handleInput
public int handleInput(byte[] buffer,
int offset,
int length)
throws IOException
- handleInput in interface Task
handleOutput
public void handleOutput(String output)
- handleOutput in interface Task
init
public void init()
Initialize this task by creating new instance of the ant task and
configuring it by calling its own init method.
- init in interface Task
setInheritAll
public void setInheritAll(boolean inherit)
If true, pass all properties to the new Ant project.
Defaults to true.
setInheritRefs
public void setInheritRefs(boolean inheritRefs)
If true, pass all references to the new Ant project.
Defaults to false.
inheritRefs
- boolean
flag.
setTarget
public void setTarget(String target)
Set target to execute.
target
- the name of the target to execute.
Copyright B) 2000-2006 Apache Software Foundation. All Rights Reserved.