logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ggreg...@apache.org
Subject svn commit: r1419697 [2/17] - in /logging/log4j/log4j2/trunk: api/src/main/java/org/apache/logging/log4j/ api/src/main/java/org/apache/logging/log4j/message/ api/src/main/java/org/apache/logging/log4j/simple/ api/src/main/java/org/apache/logging/log4j/...
Date Mon, 10 Dec 2012 19:37:03 GMT
Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/MapMessage.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/MapMessage.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/MapMessage.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/MapMessage.java Mon Dec 10 19:36:06 2012
@@ -56,14 +56,14 @@ public class MapMessage implements Multi
      * Constructor based on an existing Map.
      * @param map The Map.
      */
-    public MapMessage(Map<String, String> map) {
+    public MapMessage(final Map<String, String> map) {
         this.data = map instanceof SortedMap ? (SortedMap<String, String>) map : new TreeMap<String, String>(map);
     }
 
     public String[] getFormats() {
-        String[] formats = new String[MapFormat.values().length];
+        final String[] formats = new String[MapFormat.values().length];
         int i = 0;
-        for (MapFormat format : MapFormat.values()) {
+        for (final MapFormat format : MapFormat.values()) {
             formats[i++] = format.name();
         }
         return formats;
@@ -105,7 +105,7 @@ public class MapMessage implements Multi
      * @param key The name of the data item.
      * @param value The value of the data item.
      */
-    public void put(String key, String value) {
+    public void put(final String key, final String value) {
         if (value == null) {
             throw new IllegalArgumentException("No value provided for key " + key);
         }
@@ -113,7 +113,7 @@ public class MapMessage implements Multi
         data.put(key, value);
     }
 
-    protected void validate(String key, String value) {
+    protected void validate(final String key, final String value) {
 
     }
 
@@ -121,7 +121,7 @@ public class MapMessage implements Multi
      * Add all the elements from the specified Map.
      * @param map The Map to add.
      */
-    public void putAll(Map<String, String> map) {
+    public void putAll(final Map<String, String> map) {
         data.putAll(map);
     }
 
@@ -130,7 +130,7 @@ public class MapMessage implements Multi
      * @param key The name of the element.
      * @return The value of the element or null if the key is not present.
      */
-    public String get(String key) {
+    public String get(final String key) {
         return data.get(key);
     }
 
@@ -139,7 +139,7 @@ public class MapMessage implements Multi
      * @param key The name of the element.
      * @return The previous value of the element.
      */
-    public String remove(String key) {
+    public String remove(final String key) {
         return data.remove(key);
     }
 
@@ -152,10 +152,10 @@ public class MapMessage implements Multi
         return asString((MapFormat) null);
     }
 
-    public String asString(String format) {
+    public String asString(final String format) {
         try {
             return asString(EnglishEnums.valueOf(MapFormat.class, format));
-        } catch (IllegalArgumentException ex) {
+        } catch (final IllegalArgumentException ex) {
             return asString();
         }
     }
@@ -165,8 +165,8 @@ public class MapMessage implements Multi
      * @param format The format identifier. Ignored in this implementation.
      * @return The formatted String.
      */
-    private String asString(MapFormat format) {
-        StringBuilder sb = new StringBuilder();
+    private String asString(final MapFormat format) {
+        final StringBuilder sb = new StringBuilder();
         if (format == null) {
             appendMap(sb);
         } else {
@@ -191,9 +191,9 @@ public class MapMessage implements Multi
         return sb.toString();
     }
 
-    public void asXML(StringBuilder sb) {
+    public void asXML(final StringBuilder sb) {
         sb.append("<Map>\n");
-        for (Map.Entry<String, String> entry : data.entrySet()) {
+        for (final Map.Entry<String, String> entry : data.entrySet()) {
             sb.append("  <Entry key=").append(entry.getKey()).append(">").append(entry.getValue()).append("</Entry>\n");
         }
         sb.append("</Map>");
@@ -215,12 +215,12 @@ public class MapMessage implements Multi
      *
      * @return The formatted message.
      */
-    public String getFormattedMessage(String[] formats) {
+    public String getFormattedMessage(final String[] formats) {
         if (formats == null || formats.length == 0) {
             return asString();
         } else {
-            for (String format : formats) {
-                for (MapFormat f : MapFormat.values()) {
+            for (final String format : formats) {
+                for (final MapFormat f : MapFormat.values()) {
                     if (f.name().equalsIgnoreCase(format)) {
                         return asString(f);
                     }
@@ -231,9 +231,9 @@ public class MapMessage implements Multi
 
     }
 
-    protected void appendMap(StringBuilder sb) {
+    protected void appendMap(final StringBuilder sb) {
         boolean first = true;
-        for (Map.Entry<String, String> entry : data.entrySet()) {
+        for (final Map.Entry<String, String> entry : data.entrySet()) {
             if (!first) {
                 sb.append(" ");
             }
@@ -242,10 +242,10 @@ public class MapMessage implements Multi
         }
     }
 
-    protected void asJSON(StringBuilder sb) {
+    protected void asJSON(final StringBuilder sb) {
         boolean first = true;
         sb.append("{");
-        for (Map.Entry<String, String> entry : data.entrySet()) {
+        for (final Map.Entry<String, String> entry : data.entrySet()) {
             if (!first) {
                 sb.append(", ");
             }
@@ -257,10 +257,10 @@ public class MapMessage implements Multi
     }
 
 
-    protected void asJava(StringBuilder sb) {
+    protected void asJava(final StringBuilder sb) {
         boolean first = true;
         sb.append("{");
-        for (Map.Entry<String, String> entry : data.entrySet()) {
+        for (final Map.Entry<String, String> entry : data.entrySet()) {
             if (!first) {
                 sb.append(", ");
             }
@@ -270,7 +270,7 @@ public class MapMessage implements Multi
         sb.append("}");
     }
 
-    public MapMessage newInstance(Map<String, String> map) {
+    public MapMessage newInstance(final Map<String, String> map) {
         return new MapMessage(map);
     }
 
@@ -280,7 +280,7 @@ public class MapMessage implements Multi
     }
 
     @Override
-    public boolean equals(Object o) {
+    public boolean equals(final Object o) {
         if (this == o) {
             return true;
         }
@@ -288,7 +288,7 @@ public class MapMessage implements Multi
             return false;
         }
 
-        MapMessage that = (MapMessage) o;
+        final MapMessage that = (MapMessage) o;
 
         return this.data.equals(that.data);
     }

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ObjectMessage.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ObjectMessage.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ObjectMessage.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ObjectMessage.java Mon Dec 10 19:36:06 2012
@@ -66,7 +66,7 @@ public class ObjectMessage implements Me
     }
 
     @Override
-    public boolean equals(Object o) {
+    public boolean equals(final Object o) {
         if (this == o) {
             return true;
         }
@@ -74,7 +74,7 @@ public class ObjectMessage implements Me
             return false;
         }
 
-        ObjectMessage that = (ObjectMessage) o;
+        final ObjectMessage that = (ObjectMessage) o;
 
         return !(obj != null ? !obj.equals(that.obj) : that.obj != null);
     }
@@ -89,7 +89,7 @@ public class ObjectMessage implements Me
         return "ObjectMessage[obj=" + obj.toString() + "]";
     }
 
-    private void writeObject(ObjectOutputStream out) throws IOException {
+    private void writeObject(final ObjectOutputStream out) throws IOException {
         out.defaultWriteObject();
         if (obj instanceof Serializable) {
             out.writeObject(obj);
@@ -98,7 +98,7 @@ public class ObjectMessage implements Me
         }
     }
 
-    private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
+    private void readObject(final ObjectInputStream in) throws IOException, ClassNotFoundException {
         in.defaultReadObject();
         obj = in.readObject();
     }

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ParameterizedMessage.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ParameterizedMessage.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ParameterizedMessage.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ParameterizedMessage.java Mon Dec 10 19:36:06 2012
@@ -82,13 +82,13 @@ public class ParameterizedMessage implem
      * @param stringArgs The arguments for substitution.
      * @param throwable A Throwable.
      */
-    public ParameterizedMessage(String messagePattern, String[] stringArgs, Throwable throwable) {
+    public ParameterizedMessage(final String messagePattern, final String[] stringArgs, final Throwable throwable) {
         this.messagePattern = messagePattern;
         this.stringArgs = stringArgs;
         this.throwable = throwable;
     }
 
-    public ParameterizedMessage(String messagePattern, Object[] arguments, Throwable throwable) {
+    public ParameterizedMessage(final String messagePattern, final Object[] arguments, final Throwable throwable) {
         this.messagePattern = messagePattern;
         this.throwable = throwable;
         if (arguments != null) {
@@ -108,7 +108,7 @@ public class ParameterizedMessage implem
      * @param messagePattern the message pattern that to be checked for placeholders.
      * @param arguments      the argument array to be converted.
      */
-    public ParameterizedMessage(String messagePattern, Object[] arguments) {
+    public ParameterizedMessage(final String messagePattern, final Object[] arguments) {
         this.messagePattern = messagePattern;
         if (arguments != null) {
             parseArguments(arguments);
@@ -120,7 +120,7 @@ public class ParameterizedMessage implem
      * @param messagePattern The message pattern.
      * @param arg The parameter.
      */
-    public ParameterizedMessage(String messagePattern, Object arg) {
+    public ParameterizedMessage(final String messagePattern, final Object arg) {
         this(messagePattern, new Object[]{arg});
     }
 
@@ -130,12 +130,12 @@ public class ParameterizedMessage implem
      * @param arg1 The first parameter.
      * @param arg2 The second parameter.
      */
-    public ParameterizedMessage(String messagePattern, Object arg1, Object arg2) {
+    public ParameterizedMessage(final String messagePattern, final Object arg1, final Object arg2) {
         this(messagePattern, new Object[]{arg1, arg2});
     }
 
-    private void parseArguments(Object[] arguments) {
-        int argsCount = countArgumentPlaceholders(messagePattern);
+    private void parseArguments(final Object[] arguments) {
+        final int argsCount = countArgumentPlaceholders(messagePattern);
         int resultArgCount = arguments.length;
         if (argsCount < arguments.length) {
             if (throwable == null && arguments[arguments.length - 1] instanceof Throwable) {
@@ -203,12 +203,12 @@ public class ParameterizedMessage implem
         return throwable;
     }
 
-    protected String formatMessage(String msgPattern, String[] sArgs) {
+    protected String formatMessage(final String msgPattern, final String[] sArgs) {
         return format(msgPattern, sArgs);
     }
 
     @Override
-    public boolean equals(Object o) {
+    public boolean equals(final Object o) {
         if (this == o) {
             return true;
         }
@@ -216,7 +216,7 @@ public class ParameterizedMessage implem
             return false;
         }
 
-        ParameterizedMessage that = (ParameterizedMessage) o;
+        final ParameterizedMessage that = (ParameterizedMessage) o;
 
         if (messagePattern != null ? !messagePattern.equals(that.messagePattern) : that.messagePattern != null) {
             return false;
@@ -243,16 +243,16 @@ public class ParameterizedMessage implem
      * @param arguments      the arguments to be used to replace placeholders.
      * @return the formatted message.
      */
-    public static String format(String messagePattern, Object[] arguments) {
+    public static String format(final String messagePattern, final Object[] arguments) {
         if (messagePattern == null || arguments == null || arguments.length == 0) {
             return messagePattern;
         }
 
-        StringBuilder result = new StringBuilder();
+        final StringBuilder result = new StringBuilder();
         int escapeCounter = 0;
         int currentArgument = 0;
         for (int i = 0; i < messagePattern.length(); i++) {
-            char curChar = messagePattern.charAt(i);
+            final char curChar = messagePattern.charAt(i);
             if (curChar == ESCAPE_CHAR) {
                 escapeCounter++;
             } else {
@@ -260,7 +260,7 @@ public class ParameterizedMessage implem
                     if (i < messagePattern.length() - 1) {
                         if (messagePattern.charAt(i + 1) == DELIM_STOP) {
                             // write escaped escape chars
-                            int escapedEscapes = escapeCounter / 2;
+                            final int escapedEscapes = escapeCounter / 2;
                             for (int j = 0; j < escapedEscapes; j++) {
                                 result.append(ESCAPE_CHAR);
                             }
@@ -305,12 +305,12 @@ public class ParameterizedMessage implem
      * @param messagePattern the message pattern to be analyzed.
      * @return the number of unescaped placeholders.
      */
-    public static int countArgumentPlaceholders(String messagePattern) {
+    public static int countArgumentPlaceholders(final String messagePattern) {
         if (messagePattern == null) {
             return 0;
         }
 
-        int delim = messagePattern.indexOf(DELIM_START);
+        final int delim = messagePattern.indexOf(DELIM_START);
 
         if (delim == -1) {
             // special case, no placeholders at all.
@@ -319,7 +319,7 @@ public class ParameterizedMessage implem
         int result = 0;
         boolean isEscaped = false;
         for (int i = 0; i < messagePattern.length(); i++) {
-            char curChar = messagePattern.charAt(i);
+            final char curChar = messagePattern.charAt(i);
             if (curChar == ESCAPE_CHAR) {
                 isEscaped = !isEscaped;
             } else if (curChar == DELIM_START) {
@@ -355,15 +355,15 @@ public class ParameterizedMessage implem
      * @param o The object.
      * @return The String representation.
      */
-    public static String deepToString(Object o) {
+    public static String deepToString(final Object o) {
         if (o == null) {
             return null;
         }
         if (o instanceof String) {
             return (String) o;
         }
-        StringBuilder str = new StringBuilder();
-        Set<String> dejaVu = new HashSet<String>(); // that's actually a neat name ;)
+        final StringBuilder str = new StringBuilder();
+        final Set<String> dejaVu = new HashSet<String>(); // that's actually a neat name ;)
         recursiveDeepToString(o, str, dejaVu);
         return str.toString();
     }
@@ -389,7 +389,7 @@ public class ParameterizedMessage implem
      * @param str    the StringBuilder that o will be appended to
      * @param dejaVu a list of container identities that were already used.
      */
-    private static void recursiveDeepToString(Object o, StringBuilder str, Set<String> dejaVu) {
+    private static void recursiveDeepToString(final Object o, final StringBuilder str, final Set<String> dejaVu) {
         if (o == null) {
             str.append("null");
             return;
@@ -399,7 +399,7 @@ public class ParameterizedMessage implem
             return;
         }
 
-        Class<?> oClass = o.getClass();
+        final Class<?> oClass = o.getClass();
         if (oClass.isArray()) {
             if (oClass == byte[].class) {
                 str.append(Arrays.toString((byte[]) o));
@@ -419,15 +419,15 @@ public class ParameterizedMessage implem
                 str.append(Arrays.toString((char[]) o));
             } else {
                 // special handling of container Object[]
-                String id = identityToString(o);
+                final String id = identityToString(o);
                 if (dejaVu.contains(id)) {
                     str.append(RECURSION_PREFIX).append(id).append(RECURSION_SUFFIX);
                 } else {
                     dejaVu.add(id);
-                    Object[] oArray = (Object[]) o;
+                    final Object[] oArray = (Object[]) o;
                     str.append("[");
                     boolean first = true;
-                    for (Object current : oArray) {
+                    for (final Object current : oArray) {
                         if (first) {
                             first = false;
                         } else {
@@ -441,23 +441,23 @@ public class ParameterizedMessage implem
             }
         } else if (o instanceof Map) {
             // special handling of container Map
-            String id = identityToString(o);
+            final String id = identityToString(o);
             if (dejaVu.contains(id)) {
                 str.append(RECURSION_PREFIX).append(id).append(RECURSION_SUFFIX);
             } else {
                 dejaVu.add(id);
-                Map<?, ?> oMap = (Map<?, ?>) o;
+                final Map<?, ?> oMap = (Map<?, ?>) o;
                 str.append("{");
                 boolean isFirst = true;
-                for (Object o1 : oMap.entrySet()) {
-                    Map.Entry<?, ?> current = (Map.Entry<?, ?>) o1;
+                for (final Object o1 : oMap.entrySet()) {
+                    final Map.Entry<?, ?> current = (Map.Entry<?, ?>) o1;
                     if (isFirst) {
                         isFirst = false;
                     } else {
                         str.append(", ");
                     }
-                    Object key = current.getKey();
-                    Object value = current.getValue();
+                    final Object key = current.getKey();
+                    final Object value = current.getValue();
                     recursiveDeepToString(key, str, new HashSet<String>(dejaVu));
                     str.append("=");
                     recursiveDeepToString(value, str, new HashSet<String>(dejaVu));
@@ -466,15 +466,15 @@ public class ParameterizedMessage implem
             }
         } else if (o instanceof Collection) {
             // special handling of container Collection
-            String id = identityToString(o);
+            final String id = identityToString(o);
             if (dejaVu.contains(id)) {
                 str.append(RECURSION_PREFIX).append(id).append(RECURSION_SUFFIX);
             } else {
                 dejaVu.add(id);
-                Collection<?> oCol = (Collection<?>) o;
+                final Collection<?> oCol = (Collection<?>) o;
                 str.append("[");
                 boolean isFirst = true;
-                for (Object anOCol : oCol) {
+                for (final Object anOCol : oCol) {
                     if (isFirst) {
                         isFirst = false;
                     } else {
@@ -485,20 +485,20 @@ public class ParameterizedMessage implem
                 str.append("]");
             }
         } else if (o instanceof Date) {
-            Date date = (Date) o;
-            SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
+            final Date date = (Date) o;
+            final SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
             // I'll leave it like this for the moment... this could probably be optimized using ThreadLocal...
             str.append(format.format(date));
         } else {
             // it's just some other Object, we can only use toString().
             try {
                 str.append(o.toString());
-            } catch (Throwable t) {
+            } catch (final Throwable t) {
                 str.append(ERROR_PREFIX);
                 str.append(identityToString(o));
                 str.append(ERROR_SEPARATOR);
-                String msg = t.getMessage();
-                String className = t.getClass().getName();
+                final String msg = t.getMessage();
+                final String className = t.getClass().getName();
                 str.append(className);
                 if (!className.equals(msg)) {
                     str.append(ERROR_MSG_SEPARATOR);
@@ -527,7 +527,7 @@ public class ParameterizedMessage implem
      * @param obj the Object that is to be converted into an identity string.
      * @return the identity string as also defined in Object.toString()
      */
-    public static String identityToString(Object obj) {
+    public static String identityToString(final Object obj) {
         if (obj == null) {
             return null;
         }

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ParameterizedMessageFactory.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ParameterizedMessageFactory.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ParameterizedMessageFactory.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ParameterizedMessageFactory.java Mon Dec 10 19:36:06 2012
@@ -28,7 +28,7 @@ public class ParameterizedMessageFactory
      * 
      * @see MessageFactory#newMessage(String, Object...)
      */
-    public Message newMessage(String message, Object... params) {
+    public Message newMessage(final String message, final Object... params) {
         return new ParameterizedMessage(message, params);
     }
 }

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/SimpleMessage.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/SimpleMessage.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/SimpleMessage.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/SimpleMessage.java Mon Dec 10 19:36:06 2012
@@ -37,7 +37,7 @@ public class SimpleMessage implements Me
      * Constructor that includes the message.
      * @param message The String message.
      */
-    public SimpleMessage(String message) {
+    public SimpleMessage(final String message) {
         this.message = message;
     }
 
@@ -66,7 +66,7 @@ public class SimpleMessage implements Me
     }
 
     @Override
-    public boolean equals(Object o) {
+    public boolean equals(final Object o) {
         if (this == o) {
             return true;
         }
@@ -74,7 +74,7 @@ public class SimpleMessage implements Me
             return false;
         }
 
-        SimpleMessage that = (SimpleMessage) o;
+        final SimpleMessage that = (SimpleMessage) o;
 
         return !(message != null ? !message.equals(that.message) : that.message != null);
     }

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StringFormattedMessage.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StringFormattedMessage.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StringFormattedMessage.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StringFormattedMessage.java Mon Dec 10 19:36:06 2012
@@ -42,7 +42,7 @@ public class StringFormattedMessage impl
     private String[] stringArgs;
     private transient String formattedMessage;
 
-    public StringFormattedMessage(String messagePattern, Object... arguments) {
+    public StringFormattedMessage(final String messagePattern, final Object... arguments) {
         this.messagePattern = messagePattern;
         this.argArray = arguments;
     }
@@ -77,17 +77,17 @@ public class StringFormattedMessage impl
         return stringArgs;
     }
 
-    protected String formatMessage(String msgPattern, Object... args) {
+    protected String formatMessage(final String msgPattern, final Object... args) {
         try {
             return String.format(msgPattern, args);
-        } catch (IllegalFormatException ife) {
+        } catch (final IllegalFormatException ife) {
             LOGGER.error("Unable to format msg: " + msgPattern, ife);
             return msgPattern;
         }
     }
 
     @Override
-    public boolean equals(Object o) {
+    public boolean equals(final Object o) {
         if (this == o) {
             return true;
         }
@@ -95,7 +95,7 @@ public class StringFormattedMessage impl
             return false;
         }
 
-        StringFormattedMessage that = (StringFormattedMessage) o;
+        final StringFormattedMessage that = (StringFormattedMessage) o;
 
         if (messagePattern != null ? !messagePattern.equals(that.messagePattern) : that.messagePattern != null) {
             return false;
@@ -121,7 +121,7 @@ public class StringFormattedMessage impl
             Arrays.toString(argArray) +  "]";
     }
 
-    private void writeObject(ObjectOutputStream out) throws IOException {
+    private void writeObject(final ObjectOutputStream out) throws IOException {
         out.defaultWriteObject();
         getFormattedMessage();
         out.writeUTF(formattedMessage);
@@ -129,17 +129,17 @@ public class StringFormattedMessage impl
         out.writeInt(argArray.length);
         stringArgs = new String[argArray.length];
         int i = 0;
-        for (Object obj : argArray) {
+        for (final Object obj : argArray) {
             stringArgs[i] = obj.toString();
             ++i;
         }
     }
 
-    private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
+    private void readObject(final ObjectInputStream in) throws IOException, ClassNotFoundException {
         in.defaultReadObject();
         formattedMessage = in.readUTF();
         messagePattern = in.readUTF();
-        int length = in.readInt();
+        final int length = in.readInt();
         stringArgs = new String[length];
         for (int i = 0; i < length; ++i) {
             stringArgs[i] = in.readUTF();

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StringFormatterMessageFactory.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StringFormatterMessageFactory.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StringFormatterMessageFactory.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StringFormatterMessageFactory.java Mon Dec 10 19:36:06 2012
@@ -28,7 +28,7 @@ public class StringFormatterMessageFacto
      * 
      * @see MessageFactory#newMessage(String, Object...)
      */
-    public Message newMessage(String message, Object... params) {
+    public Message newMessage(final String message, final Object... params) {
         return new StringFormattedMessage(message, params);
     }
 }

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StructuredDataId.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StructuredDataId.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StructuredDataId.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StructuredDataId.java Mon Dec 10 19:36:06 2012
@@ -53,7 +53,7 @@ public class StructuredDataId implements
     private final String[] optional;
 
 
-    protected StructuredDataId(String name, String[] required, String[] optional) {
+    protected StructuredDataId(final String name, final String[] required, final String[] optional) {
         int index = -1;
         if (name != null) {
             if (name.length() > MAX_LENGTH) {
@@ -81,7 +81,7 @@ public class StructuredDataId implements
      * @param required         The list of keys that are required for this id.
      * @param optional         The list of keys that are optional for this id.
      */
-    public StructuredDataId(String name, int enterpriseNumber, String[] required, String[] optional) {
+    public StructuredDataId(final String name, final int enterpriseNumber, final String[] required, final String[] optional) {
         if (name == null) {
             throw new IllegalArgumentException("No structured id name was supplied");
         }
@@ -93,7 +93,7 @@ public class StructuredDataId implements
         }
         this.name = name;
         this.enterpriseNumber = enterpriseNumber;
-        String id = enterpriseNumber < 0 ? name : name + "@" + enterpriseNumber;
+        final String id = enterpriseNumber < 0 ? name : name + "@" + enterpriseNumber;
         if (id.length() > MAX_LENGTH) {
             throw new IllegalArgumentException("Length of id exceeds maximum of 32 characters: " + id);
         }
@@ -106,7 +106,7 @@ public class StructuredDataId implements
      * @param id The original StructuredDataId.
      * @return the new StructuredDataId.
      */
-    public StructuredDataId makeId(StructuredDataId id) {
+    public StructuredDataId makeId(final StructuredDataId id) {
         if (id == null) {
             return this;
         }
@@ -119,7 +119,7 @@ public class StructuredDataId implements
      * @param enterpriseNumber The enterprise number.
      * @return a StructuredDataId.
      */
-    public StructuredDataId makeId(String defaultId, int enterpriseNumber) {
+    public StructuredDataId makeId(final String defaultId, final int enterpriseNumber) {
         String id;
         String[] req;
         String[] opt;

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StructuredDataMessage.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StructuredDataMessage.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StructuredDataMessage.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/StructuredDataMessage.java Mon Dec 10 19:36:06 2012
@@ -65,7 +65,7 @@ public class StructuredDataMessage exten
      * @param data The StructuredData map.
      */
     public StructuredDataMessage(final String id, final String msg, final String type,
-                                 Map<String, String> data) {
+                                 final Map<String, String> data) {
         super(data);
         this.id = new StructuredDataId(id, null, null);
         this.message = msg;
@@ -92,7 +92,7 @@ public class StructuredDataMessage exten
      * @param data The StructuredData map.
      */
     public StructuredDataMessage(final StructuredDataId id, final String msg, final String type,
-                                 Map<String, String> data) {
+                                 final Map<String, String> data) {
         super(data);
         this.id = id;
         this.message = msg;
@@ -105,7 +105,7 @@ public class StructuredDataMessage exten
      * @param msg The StructuredDataMessage.
      * @param map The StructuredData map.
      */
-    private StructuredDataMessage(StructuredDataMessage msg, Map<String, String> map) {
+    private StructuredDataMessage(final StructuredDataMessage msg, final Map<String, String> map) {
         super(map);
         this.id = msg.id;
         this.message = msg.message;
@@ -126,9 +126,9 @@ public class StructuredDataMessage exten
      */
     @Override
     public String[] getFormats() {
-        String[] formats = new String[Format.values().length];
+        final String[] formats = new String[Format.values().length];
         int i = 0;
-        for (Format format : Format.values()) {
+        for (final Format format : Format.values()) {
             formats[i++] = format.name();
         }
         return formats;
@@ -146,7 +146,7 @@ public class StructuredDataMessage exten
      * Set the id from a String.
      * @param id The String id.
      */
-    protected void setId(String id) {
+    protected void setId(final String id) {
         this.id = new StructuredDataId(id, null, null);
     }
 
@@ -154,7 +154,7 @@ public class StructuredDataMessage exten
      * Set the id.
      * @param id The StructuredDataId.
      */
-    protected void setId(StructuredDataId id) {
+    protected void setId(final StructuredDataId id) {
         this.id = id;
     }
 
@@ -166,7 +166,7 @@ public class StructuredDataMessage exten
         return type;
     }
 
-    protected void setType(String type) {
+    protected void setType(final String type) {
         if (type.length() > MAX_LENGTH) {
             throw new IllegalArgumentException("Structured data type exceeds maximum length of 32 characters: " + type);
         }
@@ -181,13 +181,13 @@ public class StructuredDataMessage exten
         return message;
     }
 
-    protected void setMessageFormat(String msg) {
+    protected void setMessageFormat(final String msg) {
         this.message = msg;
     }
 
 
     @Override
-    protected void validate(String key, String value) {
+    protected void validate(final String key, final String value) {
         if (key.length() > MAX_LENGTH) {
             throw new IllegalArgumentException("Structured data keys are limited to 32 characters. key: " + key +
                 " value: " + value);
@@ -212,10 +212,10 @@ public class StructuredDataMessage exten
      */
 
     @Override
-    public String asString(String format) {
+    public String asString(final String format) {
         try {
             return asString(EnglishEnums.valueOf(Format.class, format), null);
-        } catch (IllegalArgumentException ex) {
+        } catch (final IllegalArgumentException ex) {
             return asString();
         }
     }
@@ -229,11 +229,11 @@ public class StructuredDataMessage exten
      *                         will be used.
      * @return The formatted String.
      */
-    public final String asString(Format format, StructuredDataId structuredDataId) {
-        StringBuilder sb = new StringBuilder();
-        boolean full = Format.FULL.equals(format);
+    public final String asString(final Format format, final StructuredDataId structuredDataId) {
+        final StringBuilder sb = new StringBuilder();
+        final boolean full = Format.FULL.equals(format);
         if (full) {
-            String type = getType();
+            final String type = getType();
             if (type == null) {
                 return sb.toString();
             }
@@ -254,7 +254,7 @@ public class StructuredDataMessage exten
         appendMap(sb);
         sb.append("]");
         if (full) {
-            String msg = getFormat();
+            final String msg = getFormat();
             if (msg != null) {
                 sb.append(" ").append(msg);
             }
@@ -281,9 +281,9 @@ public class StructuredDataMessage exten
      * @return the formatted message.
      */
     @Override
-    public String getFormattedMessage(String[] formats) {
+    public String getFormattedMessage(final String[] formats) {
         if (formats != null && formats.length > 0) {
-            for (String format : formats) {
+            for (final String format : formats) {
                 if (Format.XML.name().equalsIgnoreCase(format)) {
                     return asXML();
                 } else if (Format.FULL.name().equalsIgnoreCase(format)) {
@@ -297,8 +297,8 @@ public class StructuredDataMessage exten
     }
 
     private String asXML() {
-        StringBuilder sb = new StringBuilder();
-        StructuredDataId id = getId();
+        final StringBuilder sb = new StringBuilder();
+        final StructuredDataId id = getId();
         if (id == null || id.getName() == null || type == null) {
             return sb.toString();
         }
@@ -317,12 +317,12 @@ public class StructuredDataMessage exten
 
 
     @Override
-    public MapMessage newInstance(Map<String, String> map) {
+    public MapMessage newInstance(final Map<String, String> map) {
         return new StructuredDataMessage(this, map);
     }
 
     @Override
-    public boolean equals(Object o) {
+    public boolean equals(final Object o) {
         if (this == o) {
             return true;
         }
@@ -330,7 +330,7 @@ public class StructuredDataMessage exten
             return false;
         }
 
-        StructuredDataMessage that = (StructuredDataMessage) o;
+        final StructuredDataMessage that = (StructuredDataMessage) o;
 
         if (!super.equals(o)) {
             return false;

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ThreadDumpMessage.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ThreadDumpMessage.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ThreadDumpMessage.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/message/ThreadDumpMessage.java Mon Dec 10 19:36:06 2012
@@ -42,9 +42,9 @@ public class ThreadDumpMessage implement
     private String formattedMessage;
 
     static {
-        Method[] methods = ThreadInfo.class.getMethods();
+        final Method[] methods = ThreadInfo.class.getMethods();
         boolean basic = true;
-        for (Method method : methods) {
+        for (final Method method : methods) {
             if (method.getName().equals("getLockInfo")) {
                 basic = false;
                 break;
@@ -57,19 +57,19 @@ public class ThreadDumpMessage implement
      * Generate a ThreadDumpMessage with a title.
      * @param title The title.
      */
-    public ThreadDumpMessage(String title) {
+    public ThreadDumpMessage(final String title) {
         this.title = title == null ? "" : title;
         threads = factory.createThreadInfo();
     }
 
-    private ThreadDumpMessage(String formattedMsg, String title) {
+    private ThreadDumpMessage(final String formattedMsg, final String title) {
         this.formattedMessage = formattedMsg;
         this.title = title == null ? "" : title;
     }
 
     @Override
     public String toString() {
-        StringBuilder sb = new StringBuilder("ThreadDumpMessage[");
+        final StringBuilder sb = new StringBuilder("ThreadDumpMessage[");
         if (this.title.length() > 0) {
             sb.append("Title=\"").append(this.title).append("\"");
         }
@@ -85,12 +85,12 @@ public class ThreadDumpMessage implement
         if (formattedMessage != null) {
             return formattedMessage;
         }
-        StringBuilder sb = new StringBuilder(title);
+        final StringBuilder sb = new StringBuilder(title);
         if (title.length() > 0) {
             sb.append("\n");
         }
-        for (Map.Entry<ThreadInformation, StackTraceElement[]> entry : threads.entrySet()) {
-            ThreadInformation info = entry.getKey();
+        for (final Map.Entry<ThreadInformation, StackTraceElement[]> entry : threads.entrySet()) {
+            final ThreadInformation info = entry.getKey();
             info.printThreadInfo(sb);
             info.printStack(sb, entry.getValue());
             sb.append("\n");
@@ -123,7 +123,7 @@ public class ThreadDumpMessage implement
         return new ThreadDumpMessageProxy(this);
     }
 
-    private void readObject(ObjectInputStream stream)
+    private void readObject(final ObjectInputStream stream)
         throws InvalidObjectException {
         throw new InvalidObjectException("Proxy required");
     }
@@ -134,10 +134,10 @@ public class ThreadDumpMessage implement
     private static class ThreadDumpMessageProxy implements Serializable {
 
         private static final long serialVersionUID = -3476620450287648269L;
-        private String formattedMsg;
-        private String title;
+        private final String formattedMsg;
+        private final String title;
 
-        public ThreadDumpMessageProxy(ThreadDumpMessage msg) {
+        public ThreadDumpMessageProxy(final ThreadDumpMessage msg) {
             this.formattedMsg = msg.getFormattedMessage();
             this.title = msg.title;
         }
@@ -163,10 +163,10 @@ public class ThreadDumpMessage implement
      */
     private static class BasicThreadInfoFactory implements ThreadInfoFactory {
         public Map<ThreadInformation, StackTraceElement[]> createThreadInfo() {
-            Map<Thread, StackTraceElement[]> map = Thread.getAllStackTraces();
-            Map<ThreadInformation, StackTraceElement[]> threads =
+            final Map<Thread, StackTraceElement[]> map = Thread.getAllStackTraces();
+            final Map<ThreadInformation, StackTraceElement[]> threads =
                 new HashMap<ThreadInformation, StackTraceElement[]>(map.size());
-            for (Map.Entry<Thread, StackTraceElement[]> entry : map.entrySet()) {
+            for (final Map.Entry<Thread, StackTraceElement[]> entry : map.entrySet()) {
                 threads.put(new BasicThreadInformation(entry.getKey()), entry.getValue());
             }
             return threads;
@@ -178,12 +178,12 @@ public class ThreadDumpMessage implement
      */
     private static class ExtendedThreadInfoFactory implements ThreadInfoFactory {
         public Map<ThreadInformation, StackTraceElement[]> createThreadInfo() {
-            ThreadMXBean bean = ManagementFactory.getThreadMXBean();
-            ThreadInfo[] array = bean.dumpAllThreads(true, true);
+            final ThreadMXBean bean = ManagementFactory.getThreadMXBean();
+            final ThreadInfo[] array = bean.dumpAllThreads(true, true);
 
-            Map<ThreadInformation, StackTraceElement[]>  threads =
+            final Map<ThreadInformation, StackTraceElement[]>  threads =
                 new HashMap<ThreadInformation, StackTraceElement[]>(array.length);
-            for (ThreadInfo info : array) {
+            for (final ThreadInfo info : array) {
                 threads.put(new ExtendedThreadInformation(info), info.getStackTrace());
             }
             return threads;

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLogger.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLogger.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLogger.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLogger.java Mon Dec 10 19:36:06 2012
@@ -46,23 +46,23 @@ public class SimpleLogger extends Abstra
 
     private Level level;
 
-    private boolean showDateTime;
+    private final boolean showDateTime;
 
-    private boolean showContextMap;
+    private final boolean showContextMap;
 
     private PrintStream stream;
 
     private String logName;
 
 
-    public SimpleLogger(String name, Level defaultLevel, boolean showLogName, boolean showShortLogName,
-                        boolean showDateTime, boolean showContextMap, String dateTimeFormat,
-                        MessageFactory messageFactory, PropsUtil props, PrintStream stream) {
+    public SimpleLogger(final String name, final Level defaultLevel, final boolean showLogName, final boolean showShortLogName,
+                        final boolean showDateTime, final boolean showContextMap, final String dateTimeFormat,
+                        final MessageFactory messageFactory, final PropsUtil props, final PrintStream stream) {
         super(name, messageFactory);
-        String lvl = props.getStringProperty(SimpleLoggerContext.SYSTEM_PREFIX + name + ".level");
+        final String lvl = props.getStringProperty(SimpleLoggerContext.SYSTEM_PREFIX + name + ".level");
         this.level = Level.toLevel(lvl, defaultLevel);
         if (showShortLogName) {
-            int index = name.lastIndexOf(".");
+            final int index = name.lastIndexOf(".");
             if (index > 0 && index < name.length()) {
                 this.logName = name.substring(index + 1);
             } else {
@@ -78,29 +78,29 @@ public class SimpleLogger extends Abstra
         if (showDateTime) {
             try {
                 this.dateFormatter = new SimpleDateFormat(dateTimeFormat);
-            } catch(IllegalArgumentException e) {
+            } catch(final IllegalArgumentException e) {
                 // If the format pattern is invalid - use the default format
                 this.dateFormatter = new SimpleDateFormat(SimpleLoggerContext.DEFAULT_DATE_TIME_FORMAT);
             }
         }
     }
 
-    public void setStream(PrintStream stream) {
+    public void setStream(final PrintStream stream) {
         this.stream = stream;
     }
 
-    public void setLevel(Level level) {
+    public void setLevel(final Level level) {
         if (level != null) {
             this.level = level;
         }
     }
 
     @Override
-    public void log(Marker marker, String fqcn, Level level, Message msg, Throwable throwable) {
-        StringBuilder sb = new StringBuilder();
+    public void log(final Marker marker, final String fqcn, final Level level, final Message msg, final Throwable throwable) {
+        final StringBuilder sb = new StringBuilder();
         // Append date-time if so configured
         if(showDateTime) {
-            Date now = new Date();
+            final Date now = new Date();
             String dateText;
             synchronized(dateFormatter) {
                 dateText = dateFormatter.format(now);
@@ -117,14 +117,14 @@ public class SimpleLogger extends Abstra
         }
         sb.append(msg.getFormattedMessage());
         if (showContextMap) {
-            Map<String, String> mdc = ThreadContext.getContext();
+            final Map<String, String> mdc = ThreadContext.getContext();
             if (mdc.size() > 0) {
                 sb.append(" ");
                 sb.append(mdc.toString());
                 sb.append(" ");
             }
         }
-        Object[] params = msg.getParameters();
+        final Object[] params = msg.getParameters();
         Throwable t;
         if (throwable == null && params != null && params[params.length -1] instanceof Throwable ) {
             t = (Throwable) params[params.length - 1];
@@ -133,7 +133,7 @@ public class SimpleLogger extends Abstra
         }
         if (t != null) {
             sb.append(" ");
-            ByteArrayOutputStream baos = new ByteArrayOutputStream();
+            final ByteArrayOutputStream baos = new ByteArrayOutputStream();
             t.printStackTrace(new PrintStream(baos));
             sb.append(baos.toString());
         }
@@ -141,28 +141,28 @@ public class SimpleLogger extends Abstra
     }
 
     @Override
-    protected boolean isEnabled(Level level, Marker marker, String msg) {
+    protected boolean isEnabled(final Level level, final Marker marker, final String msg) {
         return this.level.intLevel() >= level.intLevel();
     }
 
 
     @Override
-    protected boolean isEnabled(Level level, Marker marker, String msg, Throwable t) {
+    protected boolean isEnabled(final Level level, final Marker marker, final String msg, final Throwable t) {
         return this.level.intLevel() >= level.intLevel();
     }
 
     @Override
-    protected boolean isEnabled(Level level, Marker marker, String msg, Object... p1) {
+    protected boolean isEnabled(final Level level, final Marker marker, final String msg, final Object... p1) {
         return this.level.intLevel() >= level.intLevel();
     }
 
     @Override
-    protected boolean isEnabled(Level level, Marker marker, Object msg, Throwable t) {
+    protected boolean isEnabled(final Level level, final Marker marker, final Object msg, final Throwable t) {
         return this.level.intLevel() >= level.intLevel();
     }
 
     @Override
-    protected boolean isEnabled(Level level, Marker marker, Message msg, Throwable t) {
+    protected boolean isEnabled(final Level level, final Marker marker, final Message msg, final Throwable t) {
         return this.level.intLevel() >= level.intLevel();
     }
 

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLoggerContext.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLoggerContext.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLoggerContext.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLoggerContext.java Mon Dec 10 19:36:06 2012
@@ -42,9 +42,9 @@ public class SimpleLoggerContext impleme
     protected static final String SYSTEM_PREFIX = "org.apache.logging.log4j.simplelog.";
 
     /** Properties loaded from simplelog.properties */
-    private Properties simpleLogProps = new Properties();
+    private final Properties simpleLogProps = new Properties();
 
-    private PropsUtil props;
+    private final PropsUtil props;
 
     /** Include the instance name in the log message? */
     private final boolean showLogName;
@@ -71,13 +71,13 @@ public class SimpleLoggerContext impleme
         showLogName = props.getBooleanProperty(SYSTEM_PREFIX + "showlogname", false);
         showShortName = props.getBooleanProperty(SYSTEM_PREFIX + "showShortLogname", true);
         showDateTime = props.getBooleanProperty(SYSTEM_PREFIX + "showdatetime", false);
-        String lvl = props.getStringProperty(SYSTEM_PREFIX + "level");
+        final String lvl = props.getStringProperty(SYSTEM_PREFIX + "level");
         defaultLevel = Level.toLevel(lvl, Level.ERROR);
 
         dateTimeFormat = showDateTime ? props.getStringProperty(SimpleLoggerContext.SYSTEM_PREFIX + "dateTimeFormat",
                 DEFAULT_DATE_TIME_FORMAT) : null;
 
-        String fileName = props.getStringProperty(SYSTEM_PREFIX + "logFile", "system.err");
+        final String fileName = props.getStringProperty(SYSTEM_PREFIX + "logFile", "system.err");
         PrintStream ps;
         if ("system.err".equalsIgnoreCase(fileName)) {
             ps = System.err;
@@ -85,22 +85,22 @@ public class SimpleLoggerContext impleme
             ps = System.out;
         } else {
             try {
-                FileOutputStream os = new FileOutputStream(fileName);
+                final FileOutputStream os = new FileOutputStream(fileName);
                 ps = new PrintStream(os);
-            } catch (FileNotFoundException fnfe) {
+            } catch (final FileNotFoundException fnfe) {
                 ps = System.err;
             }
         }
         this.stream = ps;
     }
 
-    private ConcurrentMap<String, Logger> loggers = new ConcurrentHashMap<String, Logger>();
+    private final ConcurrentMap<String, Logger> loggers = new ConcurrentHashMap<String, Logger>();
 
-    public Logger getLogger(String name) {
+    public Logger getLogger(final String name) {
         return getLogger(name, null);
     }
 
-    public Logger getLogger(String name, MessageFactory messageFactory) {
+    public Logger getLogger(final String name, final MessageFactory messageFactory) {
         if (loggers.containsKey(name)) {
             final Logger logger = loggers.get(name);
             AbstractLogger.checkMessageFactory(logger, messageFactory);
@@ -112,7 +112,7 @@ public class SimpleLoggerContext impleme
         return loggers.get(name);
     }
 
-    public boolean hasLogger(String name) {
+    public boolean hasLogger(final String name) {
         return false;
     }
 

Modified: logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLoggerContextFactory.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLoggerContextFactory.java?rev=1419697&r1=1419696&r2=1419697&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLoggerContextFactory.java (original)
+++ logging/log4j/log4j2/trunk/api/src/main/java/org/apache/logging/log4j/simple/SimpleLoggerContextFactory.java Mon Dec 10 19:36:06 2012
@@ -26,7 +26,7 @@ public class SimpleLoggerContextFactory 
 
     private static LoggerContext context = new SimpleLoggerContext();
 
-    public LoggerContext getContext(String FQCN, ClassLoader loader, boolean currentContext) {
+    public LoggerContext getContext(final String FQCN, final ClassLoader loader, final boolean currentContext) {
         return context;
     }
 }



Mime
View raw message