Browse Source

Add a method replaceProperties(Project,String). This delegates directly to replaceProperties(Project,String,HashMap). The Map parameter contains all the properties in Project.

This makes it easier to have a lighter coupling between tasks and Project.


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@270062 13f79535-47bb-0310-9956-ffa450edef68
master
Peter Donald 23 years ago
parent
commit
150cad6b1e
1 changed files with 13 additions and 1 deletions
  1. +13
    -1
      src/main/org/apache/tools/ant/ProjectHelper.java

+ 13
- 1
src/main/org/apache/tools/ant/ProjectHelper.java View File

@@ -722,7 +722,19 @@ public class ProjectHelper {
IntrospectionHelper ih = IntrospectionHelper.getHelper(parent.getClass());
ih.storeElement(project, parent, child, tag);
}

/**
* Replace ${} style constructions in the given value with the string value of
* the corresponding data types.
*
* @param value the string to be scanned for property references.
* @since 1.5
*/
public static String replaceProperties(Project project, String value)
throws BuildException {
return replaceProperties(project,value,project.getProperties());
}

/**
* Replace ${} style constructions in the given value with the string value of
* the corresponding data types.


Loading…
Cancel
Save