Package org.jboss.jca.sjc.ant
Class AbstractHostPortTask
- java.lang.Object
-
- org.apache.tools.ant.ProjectComponent
-
- org.apache.tools.ant.Task
-
- org.jboss.jca.sjc.ant.AbstractHostPortTask
-
- All Implemented Interfaces:
Cloneable
public abstract class AbstractHostPortTask extends org.apache.tools.ant.TaskAn abstract host/port task- Author:
- Jesper Pedersen
-
-
Constructor Summary
Constructors Constructor Description AbstractHostPortTask()Constructor
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract voidexecute()Executeprotected SerializableexecuteCommand(String command)Execute commandprotected SerializableexecuteCommand(String command, Serializable[] arguments)Execute commandStringgetHost()Get the hostintgetPort()Get the portprotected booleanisCommandAvailable(String command)Is a command availableprotected booleanisLocal()Is localvoidsetHost(String v)Set the hostvoidsetPort(int v)Set the port-
Methods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
-
-
-
-
Method Detail
-
getHost
public String getHost()
Get the host- Returns:
- The value
-
setHost
public void setHost(String v)
Set the host- Parameters:
v- The value
-
getPort
public int getPort()
Get the port- Returns:
- The value
-
setPort
public void setPort(int v)
Set the port- Parameters:
v- The value
-
isLocal
protected boolean isLocal()
Is local- Returns:
- True if local; otherwise false
-
isCommandAvailable
protected boolean isCommandAvailable(String command) throws Throwable
Is a command available- Parameters:
command- The command name- Returns:
- True if available; otherwise false
- Throws:
Throwable- If an error occurs
-
executeCommand
protected Serializable executeCommand(String command) throws Throwable
Execute command- Parameters:
command- The command- Returns:
- The result
- Throws:
Throwable- If an error occurs
-
executeCommand
protected Serializable executeCommand(String command, Serializable[] arguments) throws Throwable
Execute command- Parameters:
command- The commandarguments- The arguments- Returns:
- The result
- Throws:
Throwable- If an error occurs
-
execute
public abstract void execute() throws org.apache.tools.ant.BuildExceptionExecute- Overrides:
executein classorg.apache.tools.ant.Task- Throws:
org.apache.tools.ant.BuildException- If the build fails
-
-