incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bdelacre...@apache.org
Subject svn commit: r904127 - /sling/trunk/installer/jcr/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/impl/FolderNameFilter.java
Date Thu, 28 Jan 2010 15:22:34 GMT
Author: bdelacretaz
Date: Thu Jan 28 15:22:34 2010
New Revision: 904127

URL: http://svn.apache.org/viewvc?rev=904127&view=rev
Log:
SLING-1334 - indicate regexp match in debug logging messages

Modified:
    sling/trunk/installer/jcr/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/impl/FolderNameFilter.java

Modified: sling/trunk/installer/jcr/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/impl/FolderNameFilter.java
URL: http://svn.apache.org/viewvc/sling/trunk/installer/jcr/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/impl/FolderNameFilter.java?rev=904127&r1=904126&r2=904127&view=diff
==============================================================================
--- sling/trunk/installer/jcr/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/impl/FolderNameFilter.java
(original)
+++ sling/trunk/installer/jcr/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/impl/FolderNameFilter.java
Thu Jan 28 15:22:34 2010
@@ -99,6 +99,7 @@
     int getPriority(final String path) {
     	int result = 0;
     	List<String> modes = null;
+    	boolean match = false;
     	
         // If path contains dots after the last /, remove suffixes 
     	// starting with dots until path matches regexp, and accept 
@@ -137,6 +138,7 @@
             }
             
         } else if(pattern.matcher(path).matches()) {
+        	match = true;
         	result = getRootPriority(path);
         }
         
@@ -144,10 +146,12 @@
             if(log.isDebugEnabled()) {
                 log.debug("getPriority(" + path + ")=" + result + " (prefix=" + prefix +
", run modes=" + modes + ")");
             }
-        } else {
+        } else if(match ){
         	log.debug("getPriority({})={}", path, result);
+        } else {
+        	log.debug("getPriority({})={}, path doesn't match regexp", path, result);
         }
-        
+         
         return result;
     }
     



Mime
View raw message