org.apache.tools.ant.taskdefs.optional

Class Script


public class Script
extends Task

Executes a script.

Field Summary

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

Method Summary

void
addText(String text)
Set the script text.
void
execute()
Do the work.
void
setLanguage(String language)
Defines the language (required).
void
setSrc(String fileName)
Load the script from an external file ; optional.

Methods inherited from class org.apache.tools.ant.Task

execute, 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, log, log, setProject

Method Details

addText

public void addText(String text)
Set the script text.
Parameters:
text - a component of the script text to be added.

execute

public void execute()
            throws BuildException
Do the work.
Overrides:
execute in interface Task
Throws:
BuildException - if something goes wrong with the build

setLanguage

public void setLanguage(String language)
Defines the language (required).
Parameters:
language - the scripting language name for the script.

setSrc

public void setSrc(String fileName)
Load the script from an external file ; optional.
Parameters:
fileName - the name of the file containing the script source.

Copyright B) 2000-2006 Apache Software Foundation. All Rights Reserved.