]> source.dussan.org Git - poi.git/commitdiff
Patch 55611 - Performance improvement in DateUtil.isADateFormat(int, String)
authorYegor Kozlov <yegor@apache.org>
Sat, 19 Oct 2013 14:12:15 +0000 (14:12 +0000)
committerYegor Kozlov <yegor@apache.org>
Sat, 19 Oct 2013 14:12:15 +0000 (14:12 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1533768 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/poi/ss/usermodel/DateUtil.java

index 49b5ad12d86cd383bf00126e55b6a3452adb8856..6bd832dfbbd130b425298b2b7092548d41bf26cd 100644 (file)
@@ -299,7 +299,7 @@ public class DateUtil {
      * @see #isInternalDateFormat(int)
      */
 
-    public static boolean isADateFormat(int formatIndex, String formatString) {
+    public static synchronized boolean isADateFormat(int formatIndex, String formatString) {
        
          if (formatString != null && formatIndex == lastFormatIndex && formatString.equals(lastFormatString)) {
                        return cached;