jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ju...@apache.org
Subject svn commit: r732867 - /jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/util/Text.java
Date Thu, 08 Jan 2009 23:03:24 GMT
Author: jukka
Date: Thu Jan  8 15:03:24 2009
New Revision: 732867

URL: http://svn.apache.org/viewvc?rev=732867&view=rev
Log:
Correct indenting.

Modified:
    jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/util/Text.java

Modified: jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/util/Text.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/util/Text.java?rev=732867&r1=732866&r2=732867&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/util/Text.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/util/Text.java
Thu Jan  8 15:03:24 2009
@@ -481,28 +481,29 @@
         }
         return buffer.toString();
     }
-    
+
     /** Escapes all illegal XPath search characters of a string.
-    * <p>Example:<br>
-    * A search string like 'test?' will run into a ParseException
-    * documented in http://issues.apache.org/jira/browse/JCR-1248
-    * 
-    * @param string the string to encode
-    * @return the escaped string    
-    */
-   public static String escapeIllegalXpathSearchChars(String s) {
-       StringBuffer sb = new StringBuffer();
-       sb.append(s.substring(0, (s.length() - 1)));
-       char c = s.charAt(s.length() - 1);
-       // NOTE: keep this in sync with _ESCAPED_CHAR below!
-       if (c == '!' || c == '(' || c == ':' || c == '^' 
-           || c == '[' || c == ']' || c == '\"' || c == '{' 
-           || c == '}' || c == '?') {
-           sb.append('\\');
-       }
-       sb.append(c);
-       return sb.toString();
-   }
+     * <p>Example:<br>
+     * A search string like 'test?' will run into a ParseException
+     * documented in http://issues.apache.org/jira/browse/JCR-1248
+     * 
+     * @param string the string to encode
+     * @return the escaped string
+     */
+    public static String escapeIllegalXpathSearchChars(String s) {
+        StringBuffer sb = new StringBuffer();
+        sb.append(s.substring(0, (s.length() - 1)));
+        char c = s.charAt(s.length() - 1);
+        // NOTE: keep this in sync with _ESCAPED_CHAR below!
+        if (c == '!' || c == '(' || c == ':' || c == '^' 
+            || c == '[' || c == ']' || c == '\"' || c == '{' 
+            || c == '}' || c == '?') {
+            sb.append('\\');
+        }
+        sb.append(c);
+        return sb.toString();
+    }
+
     /**
      * Unescapes previously escaped jcr chars.
      * <p/>



Mime
View raw message