svn commit: r1859928 - in /ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util: StringUtil.java test/StringUtilTests.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r1859928 - in /ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util: StringUtil.java test/StringUtilTests.java

mthl
Author: mthl
Date: Sat May 25 09:22:58 2019
New Revision: 1859928

URL: http://svn.apache.org/viewvc?rev=1859928&view=rev
Log:
Improved: Remove unused ‘StringUtil#removeNumeric’ method
(OFBIZ-11014)

Modified:
    ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/StringUtil.java
    ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/test/StringUtilTests.java

Modified: ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/StringUtil.java
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/StringUtil.java?rev=1859928&r1=1859927&r2=1859928&view=diff
==============================================================================
--- ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/StringUtil.java (original)
+++ ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/StringUtil.java Sat May 25 09:22:58 2019
@@ -364,11 +364,6 @@ public class StringUtil {
         return removeRegex(str,"[\\D]");
     }
 
-    /** Removes all numbers from str */
-    public static String removeNumeric(String str) {
-        return removeRegex(str,"[\\d]");
-    }
-
     /**
      * @param str
      * @param regex

Modified: ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/test/StringUtilTests.java
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/test/StringUtilTests.java?rev=1859928&r1=1859927&r2=1859928&view=diff
==============================================================================
--- ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/test/StringUtilTests.java (original)
+++ ofbiz/ofbiz-framework/trunk/framework/base/src/main/java/org/apache/ofbiz/base/util/test/StringUtilTests.java Sat May 25 09:22:58 2019
@@ -196,10 +196,6 @@ public class StringUtilTests extends Gen
         assertEquals("just numbers", "12345", StringUtil.removeNonNumeric("a1'2;3]4!5("));
     }
 
-    public void testRemoveNumeric() {
-        assertEquals("only numbers", "a';]!(", StringUtil.removeNumeric("a1'2;3]4!5("));
-    }
-
     public void testRemoveRegex() {
     }