public class DotNetExecTask
extends org.apache.tools.ant.taskdefs.ExecTask
Constructor and Description |
---|
DotNetExecTask()
Empty Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
execute()
Do the work.
|
static DotNetExecTask |
getTask(org.apache.tools.ant.Task t,
java.lang.String vm,
java.lang.String executable,
org.apache.tools.ant.types.Environment env)
Creates an instance of this task based on a different tasks settings.
|
void |
internalSetErrorProperty(java.lang.String name)
Sets the name of the property to set if execution fails.
|
protected static boolean |
isMono(java.lang.String vm)
Whether the given vm looks like the Mono executable.
|
protected void |
maybeSetResultPropertyValue(int result)
Overridden to support the error-property handling required by
NUnit, NAnt and friends.
|
void |
setExecutable(java.lang.String value)
Set the name of the executable program.
|
protected void |
setupCommandline()
If the inherited Commandline doesn't know about the executable
yet, set it and deal with the vm attribute.
|
void |
setVm(java.lang.String value)
Set the name of the executable for the virtual machine or the
magic name "microsoft" which implies that we can invoke the
executable directly.
|
addConfiguredRedirector, addEnv, checkConfiguration, createArg, createHandler, createWatchdog, getOs, getOsFamily, getResolveExecutable, isValidOs, logFlush, prepareExec, resolveExecutable, runExec, runExecute, setAppend, setCommand, setDir, setError, setErrorProperty, setFailIfExecutionFails, setFailonerror, setInput, setInputString, setLogError, setNewenvironment, setOs, setOsFamily, setOutput, setOutputproperty, setResolveExecutable, setResultProperty, setSearchPath, setSpawn, setTimeout, setTimeout, setupRedirector, setVMLauncher
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
public void setExecutable(java.lang.String value)
setExecutable
in class org.apache.tools.ant.taskdefs.ExecTask
value
- the name of the executable programpublic void setVm(java.lang.String value)
value
- the name of the executable for the virtual machinepublic void internalSetErrorProperty(java.lang.String name)
Not exposed as an attribute of the task, it just supports tasks like <nunit> which delegate to instances of this class.
public void execute() throws org.apache.tools.ant.BuildException
execute
in class org.apache.tools.ant.taskdefs.ExecTask
org.apache.tools.ant.BuildException
- if executable is empty or <exec>
throws an exception.protected void maybeSetResultPropertyValue(int result)
maybeSetResultPropertyValue
in class org.apache.tools.ant.taskdefs.ExecTask
protected void setupCommandline()
The inherited Commandline may know the executable already if this task instance is getting reused.
protected static final boolean isMono(java.lang.String vm)
public static DotNetExecTask getTask(org.apache.tools.ant.Task t, java.lang.String vm, java.lang.String executable, org.apache.tools.ant.types.Environment env)