Package org.apache.tools.ant.taskdefs
Class Replace.Replacefilter
java.lang.Object
org.apache.tools.ant.taskdefs.Replace.Replacefilter
- Enclosing class:
- Replace
A filter to apply.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionCreate a token to filter as the text of a nested element.Create a string to replace the token as the text of a nested element.Get the name of the property whose value is to serve as the replacement value.Get the replacement value for this filter token.getToken()Get the string to search for.getValue()Get replacementString.voidsetProperty(String property) Set the name of the property whose value is to serve as the replacement value; required ifvalueis not set.voidSet the token to replace.voidThe replacement string; required ifpropertyis not set.voidvalidate()Validate the filter's configuration.
-
Constructor Details
-
Replacefilter
public Replacefilter()
-
-
Method Details
-
validate
Validate the filter's configuration.- Throws:
BuildException- if any part is invalid.
-
getReplaceValue
Get the replacement value for this filter token.- Returns:
- the replacement value
-
setToken
Set the token to replace.- Parameters:
t-Stringtoken.
-
getToken
Get the string to search for.- Returns:
- current
Stringtoken.
-
setValue
The replacement string; required ifpropertyis not set.- Parameters:
value-Stringvalue to replace.
-
getValue
Get replacementString.- Returns:
- replacement or null.
-
setProperty
Set the name of the property whose value is to serve as the replacement value; required ifvalueis not set.- Parameters:
property- property name.
-
getProperty
Get the name of the property whose value is to serve as the replacement value.- Returns:
- property or null.
-
createReplaceToken
Create a token to filter as the text of a nested element.- Returns:
- nested token
NestedStringto configure. - Since:
- Ant 1.8.0
-
createReplaceValue
Create a string to replace the token as the text of a nested element.- Returns:
- replacement value
NestedStringto configure. - Since:
- Ant 1.8.0
-