You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by gg...@apache.org on 2014/03/24 21:09:31 UTC

svn commit: r1581026 - /logging/log4j/log4j2/trunk/log4j-api/src/main/java/org/apache/logging/log4j/Level.java

Author: ggregory
Date: Mon Mar 24 20:09:31 2014
New Revision: 1581026

URL: http://svn.apache.org/r1581026
Log:
Add missing API from version 1.2: org.apache.logging.log4j.Level.isGreaterOrEqual(Level).

Modified:
    logging/log4j/log4j2/trunk/log4j-api/src/main/java/org/apache/logging/log4j/Level.java

Modified: logging/log4j/log4j2/trunk/log4j-api/src/main/java/org/apache/logging/log4j/Level.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/log4j-api/src/main/java/org/apache/logging/log4j/Level.java?rev=1581026&r1=1581025&r2=1581026&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/log4j-api/src/main/java/org/apache/logging/log4j/Level.java (original)
+++ logging/log4j/log4j2/trunk/log4j-api/src/main/java/org/apache/logging/log4j/Level.java Mon Mar 24 20:09:31 2014
@@ -147,6 +147,16 @@ public final class Level implements Comp
     }
 
     /**
+     * Compares the given Level against this one.
+     * 
+     * @param level The level to test.
+     * @return True if the given Level is less specific or the same than this Level.
+     */
+    public boolean isGreaterOrEqual(final Level level) {
+        return this.intLevel >= level.intLevel;
+    }
+
+    /**
      * Compares the specified Level against this one.
      * @param level The level to check.
      * @return True if the passed Level is more specific or the same as this Level.