document regex

git-svn-id: https://svn.apache.org/repos/asf/ant/antlibs/props/trunk@916767 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/src/main/org/apache/ant/props/ConditionEvaluator.java b/src/main/org/apache/ant/props/ConditionEvaluator.java
index 998988d..e71a6aa 100644
--- a/src/main/org/apache/ant/props/ConditionEvaluator.java
+++ b/src/main/org/apache/ant/props/ConditionEvaluator.java
@@ -40,11 +40,33 @@
     private static final Pattern COMMA = Pattern.compile(",");
     private static final Pattern EQ = Pattern.compile("=");
 
+    private static final String PATTERN = "^" // beginning
+            + "(!)?" // optional bang implying NOT
+            + "(.+?)" // reluctant one-or-more characters !LPAREN (see next)
+            + "\\(" // LPAREN
+            + "(" // capturing group 1
+            + "(?:" // noncapturing group for first attribute assignment
+            + "(?:.+?)" // reluctant one or more !=
+            + "=" // equals
+            + "(?:.+?)" // reluctant one or more !,
+            + ")?" //
+            + "(?:" // noncapturing group of additional attribute assignments
+            + "," // delimiting comma
+            + "(?:.+?)" // noncapturing reluctant 1 or more !=
+            + "=" // equals
+            + "(?:.+?)" // noncapturing reluctant 1 or more
+            + ")*" // 0 or more additional attributes
+            + "?" // 0 or 1 sets of attributes
+            + ")" // end capturing group 1
+            + "\\)" // RPAREN
+            + "$" // EOF
+    ;
+
     /**
      * Create a new ConditionEvaluator instance.
      */
     public ConditionEvaluator() {
-        super("^(!)?(.+?)\\(((?:(?:.+?)=(?:.+?))?(?:,(?:.+?)=(?:.+?))*?)\\)$");
+        super(PATTERN);
     }
 
     /**