You are viewing a plain text version of this content. The canonical link for it is here.
Posted to svn@forrest.apache.org by th...@apache.org on 2008/12/02 12:53:29 UTC

svn commit: r722433 - /forrest/branches/dispatcher_rewrite/plugins/org.apache.forrest.plugin.internal.dispatcher/src/java/org/apache/forrest/dispatcher/impl/helper/AXIOMXPathCreate.java

Author: thorsten
Date: Tue Dec  2 03:53:29 2008
New Revision: 722433

URL: http://svn.apache.org/viewvc?rev=722433&view=rev
Log:
white noise - formating changes

Modified:
    forrest/branches/dispatcher_rewrite/plugins/org.apache.forrest.plugin.internal.dispatcher/src/java/org/apache/forrest/dispatcher/impl/helper/AXIOMXPathCreate.java

Modified: forrest/branches/dispatcher_rewrite/plugins/org.apache.forrest.plugin.internal.dispatcher/src/java/org/apache/forrest/dispatcher/impl/helper/AXIOMXPathCreate.java
URL: http://svn.apache.org/viewvc/forrest/branches/dispatcher_rewrite/plugins/org.apache.forrest.plugin.internal.dispatcher/src/java/org/apache/forrest/dispatcher/impl/helper/AXIOMXPathCreate.java?rev=722433&r1=722432&r2=722433&view=diff
==============================================================================
--- forrest/branches/dispatcher_rewrite/plugins/org.apache.forrest.plugin.internal.dispatcher/src/java/org/apache/forrest/dispatcher/impl/helper/AXIOMXPathCreate.java (original)
+++ forrest/branches/dispatcher_rewrite/plugins/org.apache.forrest.plugin.internal.dispatcher/src/java/org/apache/forrest/dispatcher/impl/helper/AXIOMXPathCreate.java Tue Dec  2 03:53:29 2008
@@ -33,7 +33,7 @@
 /**
  * Issue: WSCOMMONS-389
  * 
- * As soon the above issue is fixed we need to drop this implementation since 
+ * As soon the above issue is fixed we need to drop this implementation since
  * this class will be go into the axiom code base.
  * 
  * @version 1.0
@@ -125,7 +125,7 @@
     OMElement element = null;
     OMNamespaceImpl localSpace = null;
     Map<String, String> map = new HashMap<String, String>();
-    String localName = cleanFromExpressions(pathPart,map);
+    String localName = cleanFromExpressions(pathPart, map);
     String[] nameSpacedNode = localName.split(":");
     if (nameSpacedNode.length == 2) {
       final String prefix = nameSpacedNode[0];
@@ -143,24 +143,24 @@
   private String cleanFromExpressions(String pathPart, Map<String, String> map) {
     Pattern pattern = Pattern.compile("(.*)\\[(.*)\\]");
     Matcher matcher = pattern.matcher(pathPart);
-    if (matcher.matches()){
-      pathPart=matcher.group(1);
+    if (matcher.matches()) {
+      pathPart = matcher.group(1);
       String expression = matcher.group(2);
-      String [] parts = expression.split("([\\s]*and[\\s]*)");
+      String[] parts = expression.split("([\\s]*and[\\s]*)");
       for (String part : parts) {
         pattern = Pattern.compile("@([a-zA-Z0-9]*)='(.*)'");
         matcher = pattern.matcher(part);
-        if (matcher.matches()){
+        if (matcher.matches()) {
           String key = matcher.group(1);
           String value = matcher.group(2);
           int end = value.indexOf("'");
-          if (end>-1){
+          if (end > -1) {
             /*
-             * if we have a ' in the expression it means that we have
-             * a xpath expression with operators other then "and". 
-             * We will use only the first one to create an attribute from it.
+             * if we have a ' in the expression it means that we have a xpath
+             * expression with operators other then "and". We will use only the
+             * first one to create an attribute from it.
              */
-            value= value.substring(0, end);
+            value = value.substring(0, end);
           }
           map.put(key, value);
         }