You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by kk...@apache.org on 2011/06/21 12:02:56 UTC

svn commit: r1137925 - /tomcat/trunk/java/org/apache/juli/OneLineFormatter.java

Author: kkolinko
Date: Tue Jun 21 10:02:56 2011
New Revision: 1137925

URL: http://svn.apache.org/viewvc?rev=1137925&view=rev
Log:
Add @Override
Use buf.add(char) when there is a single character string

Modified:
    tomcat/trunk/java/org/apache/juli/OneLineFormatter.java

Modified: tomcat/trunk/java/org/apache/juli/OneLineFormatter.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/juli/OneLineFormatter.java?rev=1137925&r1=1137924&r2=1137925&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/juli/OneLineFormatter.java (original)
+++ tomcat/trunk/java/org/apache/juli/OneLineFormatter.java Tue Jun 21 10:02:56 2011
@@ -59,6 +59,7 @@ public class OneLineFormatter extends Fo
      */
     private static final ThreadLocal<DateFormatCache> localDateCache =
             new ThreadLocal<DateFormatCache>() {
+        @Override
         protected DateFormatCache initialValue() {
             return new DateFormatCache(localCacheSize, timeFormat, globalDateCache);
         }
@@ -104,12 +105,12 @@ public class OneLineFormatter extends Fo
     protected void addTimestamp(StringBuilder buf, long timestamp) {
         buf.append(localDateCache.get().getFormat(timestamp));
         long frac = timestamp % 1000;
-        buf.append(".");
+        buf.append('.');
         if (frac < 100) {
             if (frac < 10) {
                 buf.append("00");
             } else {
-                buf.append("0");
+                buf.append('0');
             }
         }
         buf.append(frac);



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org