commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bay...@apache.org
Subject cvs commit: jakarta-commons-sandbox/lang/src/java/org/apache/commons/lang Strings.java
Date Thu, 04 Jul 2002 20:45:00 GMT
bayard      2002/07/04 13:45:00

  Modified:    lang/src/java/org/apache/commons/lang Strings.java
  Log:
  Removed the interpolate method. Will resurface in Util.Interpolator.
  
  Revision  Changes    Path
  1.13      +1 -21     jakarta-commons-sandbox/lang/src/java/org/apache/commons/lang/Strings.java
  
  Index: Strings.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons-sandbox/lang/src/java/org/apache/commons/lang/Strings.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- Strings.java	4 Jul 2002 20:28:15 -0000	1.12
  +++ Strings.java	4 Jul 2002 20:45:00 -0000	1.13
  @@ -1270,26 +1270,6 @@
           return buffer.toString();
       }
   
  -    /**
  -     * Interpolate variables into a String using the ${} type syntax.
  -     * 
  -     * @param text  the text to interpolate into
  -     * @param map  the map of parameters to insert
  -     * @return the updated string
  -     */
  -    public static String interpolate(String text, Map map) {
  -        Iterator keys = map.keySet().iterator();
  -        while (keys.hasNext()) {
  -            String key = keys.next().toString();
  -            String value = map.get(key).toString();
  -            text = replace(text, "${"+key+"}", value);
  -            if (key.indexOf(" ") == -1) {
  -                text = replace(text, "$"+key, value);
  -            }
  -        }
  -        return text;
  -    }
  -
       // Padding
       //--------------------------------------------------------------------------
       
  
  
  

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message