logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ggreg...@apache.org
Subject svn commit: r1501426 - /logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FileAppender.java
Date Tue, 09 Jul 2013 18:24:23 GMT
Author: ggregory
Date: Tue Jul  9 18:24:23 2013
New Revision: 1501426

URL: http://svn.apache.org/r1501426
Log:
Remove wasted boxing and unboxing.

Modified:
    logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FileAppender.java

Modified: logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FileAppender.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FileAppender.java?rev=1501426&r1=1501425&r2=1501426&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FileAppender.java
(original)
+++ logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FileAppender.java
Tue Jul  9 18:24:23 2013
@@ -109,18 +109,18 @@ public final class FileAppender<T extend
                                               @PluginAttr("advertiseURI") final String advertiseURI,
                                               @PluginConfiguration final Configuration config)
{
 
-        final boolean isAppend = append == null ? true : Boolean.valueOf(append);
-        final boolean isLocking = locking == null ? false : Boolean.valueOf(locking);
-        boolean isBuffered = bufferedIO == null ? true : Boolean.valueOf(bufferedIO);
-        final boolean isAdvertise = advertise == null ? false : Boolean.valueOf(advertise);
+        final boolean isAppend = append == null ? true : Boolean.parseBoolean(append);
+        final boolean isLocking = locking == null ? false : Boolean.parseBoolean(locking);
+        boolean isBuffered = bufferedIO == null ? true : Boolean.parseBoolean(bufferedIO);
+        final boolean isAdvertise = advertise == null ? false : Boolean.parseBoolean(advertise);
         if (isLocking && isBuffered) {
             if (bufferedIO != null) {
                 LOGGER.warn("Locking and buffering are mutually exclusive. No buffering will
occur for " + fileName);
             }
             isBuffered = false;
         }
-        final boolean isFlush = immediateFlush == null ? true : Boolean.valueOf(immediateFlush);
-        final boolean handleExceptions = suppress == null ? true : Boolean.valueOf(suppress);
+        final boolean isFlush = immediateFlush == null ? true : Boolean.parseBoolean(immediateFlush);
+        final boolean handleExceptions = suppress == null ? true : Boolean.parseBoolean(suppress);
 
         if (name == null) {
             LOGGER.error("No name provided for FileAppender");



Mime
View raw message