subant can be used with directory sets to execute a build from different directories. 2 different options are offered
| Modifier and Type | Field and Description |
|---|---|
| private Ant | |
| private String | |
| private Path | |
| private boolean | |
| private File | |
| private boolean | |
| private boolean | |
| private String | |
| private List | |
| private List | |
| private List | |
| private String | |
| private List | targets
the targets to call on the new project |
| private boolean |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | add(ResourceCollection
the resource collection to add. rc)Adds a resource collection to the implicit build path. |
| public void | addConfiguredTarget(Ant.
the tTargetElement to add.Add a target to this Ant invocation. |
| public void | |
| public void | addFilelist(FileList
the file list to add. list)Adds an ordered file list to the implicit build path. |
| public void | |
| public void | addProperty(Property
the property to pass on explicitly to the sub-build. p)Corresponds to |
| public void | |
| public void | addReference(Ant.
the reference to pass on explicitly to the sub-build. rCorresponds to |
| private static void | copyProperty(Property
the destination property whose content is modified. to, Property the source property whose content is copied. from)Assigns an Ant property to another. |
| private Ant | Returns: the ant task, configured with the explicit properties and references necessary to run the sub-build.: if not null the directory where the build should run directory)Creates the <ant> task configured to run a specific target. |
| public Path | Returns: the newly created nested build path.Creates a nested build path, and add it to the implicit build path. |
| public Path. | Returns: the newly created nested build path element.Creates a nested |
| public void | |
| private void | |
| private Path | |
| protected String | Returns: the name of the default fileGet the default build file name to use when launching the task. |
| public void | handleErrorFlush(String
The error output to log. Should not be output)null.Overrides org. |
| public void | handleErrorOutput(String
The error output to log. Should not be output)null.Overrides org. |
| public void | handleFlush(String
The output to log. Should not be output)null.Overrides org. |
| public int | Returns: the number of bytes readthe buffer into which data is to be read. buffer, int the offset into the buffer at which data is stored. offset, int the amount of data to read length)Overrides org. |
| public void | handleOutput(String
a line of output output)Overrides org. |
| private boolean | |
| public void | setAntfile(String
the short build file name. Defaults to "build.xml". antfile)This method builds the file name to use in conjunction with directories. |
| public void | setBuildpath(Path
an Ant Path object containing the buildpath. s)Set the buildpath to be used to find sub-projects. |
| public void | setBuildpathRef(Reference
a reference to an Ant Path object containing the buildpath. r)Buildpath to use, by reference. |
| public void | setFailonerror(boolean
the new value for this boolean flag. failOnError)Sets whether to fail with a build exception on error, or go on. |
| public void | setGenericAntfile(File
(path of the generic ant file, absolute or relative to
project base directory) afile)This method builds a file path to use in conjunction with directories. |
| public void | setInheritall(boolean
the new value for this boolean flag. b)Corresponds to |
| public void | setInheritrefs(boolean
the new value for this boolean flag. b)Corresponds to |
| public void | |
| public void | |
| public void | setVerbose(boolean
true to enable verbose mode, false otherwise (default). on)Enable/ disable verbose log messages showing when each sub-build path is entered/ exited. |
| ant | back to summary |
|---|---|
| private Ant ant | |
| antfile | back to summary |
|---|---|
| private String antfile | |
| buildpath | back to summary |
|---|---|
| private Path buildpath | |
| failOnError | back to summary |
|---|---|
| private boolean failOnError | |
| genericantfile | back to summary |
|---|---|
| private File genericantfile | |
| inheritAll | back to summary |
|---|---|
| private boolean inheritAll | |
| inheritRefs | back to summary |
|---|---|
| private boolean inheritRefs | |
| output | back to summary |
|---|---|
| private String output | |
| properties | back to summary |
|---|---|
| private List<Property> properties | |
| propertySets | back to summary |
|---|---|
| private List<PropertySet> propertySets | |
| references | back to summary |
|---|---|
| private List<Ant. | |
| subTarget | back to summary |
|---|---|
| private String subTarget | |
| targets | back to summary |
|---|---|
| private List<Ant. the targets to call on the new project | |
| verbose | back to summary |
|---|---|
| private boolean verbose | |
| SubAnt | back to summary |
|---|---|
| public SubAnt() | |
| add | back to summary |
|---|---|
| public void add(ResourceCollection rc) Adds a resource collection to the implicit build path.
| |
| addConfiguredTarget | back to summary |
|---|---|
| public void addConfiguredTarget(Ant. Add a target to this Ant invocation.
| |
| addDirset | back to summary |
|---|---|
| public void addDirset(DirSet set) Adds a directory set to the implicit build path. Note that the directories will be added to the build path in no particular order, so if order is significant, one should use a file list instead!
| |
| addFilelist | back to summary |
|---|---|
| public void addFilelist(FileList list) Adds an ordered file list to the implicit build path. Note that contrary to file and directory sets, file lists can reference non-existent files or directories!
| |
| addFileset | back to summary |
|---|---|
| public void addFileset(FileSet set) Adds a file set to the implicit build path. Note that the directories will be added to the build path in no particular order, so if order is significant, one should use a file list instead!
| |
| addProperty | back to summary |
|---|---|
| public void addProperty(Property p) Corresponds to
| |
| addPropertyset | back to summary |
|---|---|
| public void addPropertyset(PropertySet ps) Corresponds to
| |
| addReference | back to summary |
|---|---|
| public void addReference(Ant. Corresponds to | |
| copyProperty | back to summary |
|---|---|
| private static void copyProperty(Property to, Property from) Assigns an Ant property to another. | |
| createAntTask | back to summary |
|---|---|
| private Ant createAntTask(File directory) Creates the <ant> task configured to run a specific target. | |
| createBuildpath | back to summary |
|---|---|
| public Path createBuildpath() Creates a nested build path, and add it to the implicit build path.
| |
| createBuildpathElement | back to summary |
|---|---|
| public Path. Creates a nested
| |
| execute | back to summary |
|---|---|
| public void execute() Overrides org. Runs the various sub-builds.
| |
| execute | back to summary |
|---|---|
| private void execute(File file, File directory) throws BuildException Runs the given target on the provided build file.
| |
| getBuildpath | back to summary |
|---|---|
| private Path getBuildpath() Gets the implicit build path, creating it if
| |
| getDefaultBuildFile | back to summary |
|---|---|
| protected String getDefaultBuildFile() Get the default build file name to use when launching the task. This function may be overridden by providers of custom ProjectHelper so they can implement easily their sub launcher.
| |
| handleErrorFlush | back to summary |
|---|---|
| public void handleErrorFlush(String output) Overrides org. Pass output sent to System.err to the new project. | |
| handleErrorOutput | back to summary |
|---|---|
| public void handleErrorOutput(String output) Overrides org. Pass output sent to System.err to the new project. | |
| handleFlush | back to summary |
|---|---|
| public void handleFlush(String output) Overrides org. Pass output sent to System.out to the new project. | |
| handleInput | back to summary |
|---|---|
| public int handleInput(byte[] buffer, int offset, int length) throws IOException Overrides org. Process input into the ant task
| |
| handleOutput | back to summary |
|---|---|
| public void handleOutput(String output) Overrides org. Pass output sent to System.out to the new project. | |
| isHardError | back to summary |
|---|---|
| private boolean isHardError(Throwable t) whether we should even try to continue after this error | |
| setAntfile | back to summary |
|---|---|
| public void setAntfile(String antfile) This method builds the file name to use in conjunction with directories. Defaults to "build.xml".
If
| |
| setBuildpath | back to summary |
|---|---|
| public void setBuildpath(Path s) Set the buildpath to be used to find sub-projects.
| |
| setBuildpathRef | back to summary |
|---|---|
| public void setBuildpathRef(Reference r) Buildpath to use, by reference.
| |
| setFailonerror | back to summary |
|---|---|
| public void setFailonerror(boolean failOnError) Sets whether to fail with a build exception on error, or go on.
| |
| setGenericAntfile | back to summary |
|---|---|
| public void setGenericAntfile(File afile) This method builds a file path to use in conjunction with directories. Use antfile is ignored.
| |
| setInheritall | back to summary |
|---|---|
| public void setInheritall(boolean b) Corresponds to
| |
| setInheritrefs | back to summary |
|---|---|
| public void setInheritrefs(boolean b) Corresponds to
| |
| setOutput | back to summary |
|---|---|
| public void setOutput(String s) Corresponds to
| |
| setTarget | back to summary |
|---|---|
| public void setTarget(String target) The target to call on the different sub-builds. Set to "" to execute the default target.
| |
| setVerbose | back to summary |
|---|---|
| public void setVerbose(boolean on) Enable/ disable verbose log messages showing when each sub-build path is entered/ exited. The default value is "false".
| |