org.xins.common.ant
Class HostnameTask

java.lang.Object
  extended byorg.apache.tools.ant.ProjectComponent
      extended byorg.apache.tools.ant.Task
          extended byorg.xins.common.ant.HostnameTask

public class HostnameTask
extends Task

Apache Ant task that determines the host name.

Since:
XINS 1.0.0
Version:
$Revision: 1.18 $ $Date: 2006/08/28 09:12:35 $
Author:
Ernst de Haan

Field Summary
static String DEFAULT_PROPERTY_NAME
          Default name for the property to set.
 
Fields inherited from class org.apache.tools.ant.Task
description, location, target, taskName, taskType, wrapper
 
Fields inherited from class org.apache.tools.ant.ProjectComponent
project
 
Constructor Summary
HostnameTask()
           
 
Method Summary
 void execute()
          Called by the project to let the task do its work.
 void setProperty(String newPropertyName)
          Sets the name of the property.
 
Methods inherited from class org.apache.tools.ant.Task
getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, maybeConfigure, perform, reconfigure, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
 
Methods inherited from class org.apache.tools.ant.ProjectComponent
getProject, setProject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_PROPERTY_NAME

public static final String DEFAULT_PROPERTY_NAME
Default name for the property to set.

See Also:
Constant Field Values
Constructor Detail

HostnameTask

public HostnameTask()
Method Detail

setProperty

public void setProperty(String newPropertyName)
Sets the name of the property. If null or "" is passed as the argument, then DEFAULT_PROPERTY_NAME is assumed.

Parameters:
newPropertyName - the name of the property to store the host name in, or null if the DEFAULT_PROPERTY_NAME should be assumed.

execute

public void execute()
             throws BuildException
Called by the project to let the task do its work.

Throws:
BuildException - if something goes wrong with the build.


See http://www.xins.org/.