org.apache.anteater.test
Class BaseTask

java.lang.Object
  |
  +--org.apache.tools.ant.ProjectComponent
        |
        +--org.apache.tools.ant.Task
              |
              +--org.apache.anteater.test.BaseTask
All Implemented Interfaces:
Groupable
Direct Known Subclasses:
ActionTask, CheckUses, ContentHandlerTask, Deploy, Matcher, MatcherSet, Undeploy

public class BaseTask
extends org.apache.tools.ant.Task
implements Groupable

Root class for all the Anteater tasks.

Since:
November 5, 2001
Version:
$Revision: 1.10 $ $Date: 2002/08/09 13:00:52 $
Author:
Ovidiu Predescu

Field Summary
protected  int debug
          Debug level for this task.
protected  boolean debugWasSet
          Whether debug was previously setup.
 
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
BaseTask()
           
 
Method Summary
 void debug(String message)
           
 int getDebug()
          Return the debug level.
 Group getGroup()
           
 void print(String message)
           
 void println(String message)
           
protected  String resolveContentURL(String contentHref)
          Retrieve the resource specified as an absolute URL or basedir-relative path.
 void setDebug(int debug)
          Set the debug level.
 void setGroup(Group group)
          Sets the group that this task belongs to.
 void setGroup(String group)
          Sets the group that this task belongs to.
 
Methods inherited from class org.apache.tools.ant.Task
execute, getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, handleErrorOutput, handleOutput, init, isInvalid, log, log, maybeConfigure, perform, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName
 
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

debug

protected int debug
Debug level for this task.


debugWasSet

protected boolean debugWasSet
Whether debug was previously setup. This is used so that local debug attributes are not overridden by the value of a debug attribute inherited from its parent.

In other words, you can specify a debug attribute in a parent element, and override it in a sub-element.

Constructor Detail

BaseTask

public BaseTask()
Method Detail

setGroup

public void setGroup(String group)
Sets the group that this task belongs to.

Specified by:
setGroup in interface Groupable
Parameters:
group - String id of an existing group.

setGroup

public void setGroup(Group group)
Sets the group that this task belongs to.

Specified by:
setGroup in interface Groupable
Parameters:
group - Group object to add this task to.

getGroup

public Group getGroup()

setDebug

public void setDebug(int debug)
Set the debug level.

Parameters:
debug - an int value

getDebug

public int getDebug()
Return the debug level.

Returns:
an int value

debug

public void debug(String message)

println

public void println(String message)

print

public void print(String message)

resolveContentURL

protected String resolveContentURL(String contentHref)
                            throws IOException
Retrieve the resource specified as an absolute URL or basedir-relative path.

Parameters:
contentHref - URL or file path pointing to resource to retrieve
Returns:
String representation of resource
IOException
See Also:
HttpRequest.createMatchObject()


Ant Functional Tester -- see Project home page for details