Package org.openbravo.base
Class AntExecutor
- java.lang.Object
-
- org.openbravo.base.AntExecutor
-
public class AntExecutor extends Object
The AntExecutor class allows to execute ant tasks in a given build.xml file.
-
-
Constructor Summary
Constructors Constructor Description AntExecutor(String buildDir)
Initializes a new AntExecutor object assigning it the build.xml file in the directory passed as parameter, the base directory is the same as the one the build.xml is in.AntExecutor(String buildFile, String baseDir)
Initializes a newly created AntExecutor object assigning it the build.xml file to execute tasks from and the base directory where they will be executed.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
runTask(String _task)
Executes an ant taskvoid
runTask(Vector<String> tasks)
Executes a set of ant tasksvoid
setProperty(String property, String value)
Set a value to a property to the project.
-
-
-
Constructor Detail
-
AntExecutor
public AntExecutor(String buildFile, String baseDir) throws Exception
Initializes a newly created AntExecutor object assigning it the build.xml file to execute tasks from and the base directory where they will be executed.- Parameters:
buildFile
- - Complete path to the build.xml filebaseDir
- - Complete path to the base directory- Throws:
Exception
- - if an error occurs loading the xml file
-
AntExecutor
public AntExecutor(String buildDir) throws Exception
Initializes a new AntExecutor object assigning it the build.xml file in the directory passed as parameter, the base directory is the same as the one the build.xml is in.- Parameters:
buildDir
- - Directory where is the build.xml file and that will be the base directory- Throws:
Exception
- - if an error occurs loading the xml file
-
-
Method Detail
-
setProperty
public void setProperty(String property, String value)
Set a value to a property to the project.- Parameters:
property
- - Property namevalue
- - Value to assign
-
runTask
public void runTask(String _task) throws Exception
Executes an ant task- Parameters:
_task
- - Name of the task to execute- Throws:
Exception
- - In case the project is not loaded
-
-