This service is useful for exploring, manipulating and executing an ant build script in its native object structure. Ant is maintained by the Jakarta project at apache.org.
The startTarget methods return a java.lang.Thread that contains the executing target. If the target needs to be stopped, call Thread.interrupt() and the thread will stop at a safe point. Copyright (c) 2002 BEA Systems, Inc.
Related Topics
AntSvc
Method Summary |
public |
|
public |
|
public |
|
public |
|
public |
|
public |
|
public |
|
public |
|
public |
|
public |
|
public void |
|
public boolean |
|
Method Detail |
publicReturns an org.apache.tools.ant.Project for the given URI. The URI must point to a valid ant build.xml file, though the file can have any name.ProjectgetProject(URIantURI)
publicReturns an org.apache.tools.ant.Project for the given Reader. The Reader must point to a valid ant xml stream. This method should only be used when the encoding of the Reader matches the declared encoding header in the xml. The default encoding is "UTF-8", so if in doubt, and the URI of the xml content is not known, create an InputStreamReader with UTF-8 as the encoding choice.ProjectgetProject(ReaderantIn)
publicReturns an org.apache.tools.ant.Project for the given String. The String must contain valid ant xml content.ProjectgetProject(StringantScript)
publicSame as getProject(URI), with the added parameter of an AntProjectConfigurator. This method is not normally used. See AntProjectConfigurator for details.ProjectgetProject(URIantURI,AntSvc.AntProjectConfiguratorconf)
Related Topics
AntSvc.AntProjectConfigurator
AntSvc.I.getProject(URI)
publicSame as getProject(Reader), with the added parameter of an AntProjectConfigurator. This method is not normally used. See AntProjectConfigurator for details.ProjectgetProject(ReaderantIn,AntSvc.AntProjectConfiguratorconf)
Related Topics
AntSvc.AntProjectConfigurator
AntSvc.I.getProject(Reader)
publicSame as getProject(String), with the added parameter of an AntProjectConfigurator. This method is not normally used. See AntProjectConfigurator for details.ProjectgetProject(StringantScript,AntSvc.AntProjectConfiguratorconf)
Related Topics
AntSvc.AntProjectConfigurator
AntSvc.I.getProject(String)
publicReturns a target key for a given Ant Project and target name. This key is need for executing the StopAntAction action or for calling stopTarget.AntSvc.AntTargetKeygetTargetKey(Projectproject,StringtargetName)
Related Topics
StopAntAction
AntSvc.I.stopTarget(AntSvc.AntTargetKey)
publicBegins the execution of the specified ant target. Execution is in a separate Thread. Output will be sent to the Ant output window. All dependent targets will be executed before the target itelf.AntSvc.AntTargetKeystartTarget(Projectproject,Stringtarget)
publicSame as startTarget, except the output gets sent to the specified IOutputWindow.AntSvc.AntTargetKeystartTarget(Projectproject,Stringtarget,OutputSvc.IOutputWindowwindow)
Related Topics
AntSvc.I.startTarget(Project, String)
OutputSvc.IOutputWindow
publicBegins the execution of an ant target in the given project, with output going to the out and err PrintStreams specified. Execution is in a separate Thread. All dependent targets will be executed before the target itself.AntSvc.AntTargetKeystartTarget(Projectproject,Stringtarget,PrintStreamout,PrintStreamerr)
public void stopTarget(AntSvc.AntTargetKey targetKey)
Stops the running target identified by the targetKey. This call blocks until
the target is stopped successfully. The targetKey can be obtained by calling
getTargetKey().
Related Topics
AntSvc.I.getTargetKey(Project, String)
public boolean waitForCompletion(AntSvc.AntTargetKey targetKey)
Once a target has been started with startTarget, this call can be used to
wait for it to finish. The return value signifies if it was interrupted.