Top Description Fields Constructors Methods
org.apache.tools.ant.taskdefs

public Class Filter

extends Task
Class Inheritance
Imports
java.io.File, org.apache.tools.ant.BuildException, .Project, .Task

Sets a token filter that is used by the file copy tasks to do token substitution. Sets multiple tokens by reading these from a file.
Since
Ant 1.1

Field Summary

Modifier and TypeField and Description
private File
private String
private String
Inherited from org.apache.tools.ant.Task:
targettaskNametaskTypewrapper

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
execute()

Overrides org.apache.tools.ant.Task.execute.

Execute the task.
protected void
readFilters()

Read the filters.

public void
setFiltersfile(File
filter file
filtersFile
)

The file from which the filters must be read.

public void
setToken(String
token to set
token
)

The token string without @ delimiters.

public void
setValue(String
token replace value
value
)

The string that should replace the token during filtered copies.

Inherited from org.apache.tools.ant.Task:
bindToOwnergetOwningTargetgetRuntimeConfigurableWrappergetTaskNamegetTaskTypegetWrapperhandleErrorFlushhandleErrorOutputhandleFlushhandleInputhandleOutputinitisInvalidloglogloglogmaybeConfigureperformreconfiguresetOwningTargetsetRuntimeConfigurableWrappersetTaskNamesetTaskType

Field Detail

filtersFileback to summary
private File filtersFile
tokenback to summary
private String token
valueback to summary
private String value

Constructor Detail

Filterback to summary
public Filter()

Method Detail

executeback to summary
public void execute() throws BuildException

Overrides org.apache.tools.ant.Task.execute.

Execute the task.

Annotations
@Override
Exceptions
BuildException:
on error
readFiltersback to summary
protected void readFilters() throws BuildException

Read the filters.

Exceptions
BuildException:
on error
setFiltersfileback to summary
public void setFiltersfile(File filtersFile)

The file from which the filters must be read. This file must be a formatted as a property file.

Parameters
filtersFile:File

filter file

setTokenback to summary
public void setToken(String token)

The token string without @ delimiters.

Parameters
token:String

token to set

setValueback to summary
public void setValue(String value)

The string that should replace the token during filtered copies.

Parameters
value:String

token replace value