cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aadamc...@apache.org
Subject svn commit: r526696 [2/3] - in /cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src: main/java/org/apache/cayenne/access/jdbc/ main/java/org/apache/cayenne/ejbql/ main/java/org/apache/cayenne/ejbql/parser/ main/jjtree/org/apache/cayenne/ejbql/ ...
Date Mon, 09 Apr 2007 09:55:04 GMT
Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDecimalLiteral.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDecimalLiteral.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDecimalLiteral.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDecimalLiteral.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLDecimalLiteral extends SimpleNode {
-	public EJBQLDecimalLiteral(int id) {
-		super(id);
-	}
 
-    EJBQLDecimalLiteral(AbstractParser parser, int id) {
+    public EJBQLDecimalLiteral(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitDecimalLiteral(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDelete.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDelete.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDelete.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDelete.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLDelete(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitDelete(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDescending.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDescending.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDescending.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDescending.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLDescending(AbstractParser parser, int id) {
-        super(id);
-    }
-    
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitDescending(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDistinct.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDistinct.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDistinct.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDistinct.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLDistinct(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitDistinct(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDistinctPath.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDistinctPath.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDistinctPath.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDistinctPath.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLDistinctPath(AbstractParser parser, int id) {
-        super(id);
-    }
-    
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitDistinctPath(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDivide.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDivide.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDivide.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLDivide.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLDivide(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitDivide(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLEquals.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLEquals.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLEquals.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLEquals.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLEquals(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitEquals(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLEscapeCharacter.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLEscapeCharacter.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLEscapeCharacter.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLEscapeCharacter.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLEscapeCharacter(AbstractParser parser, int id) {
-        super(id);
-    }
-    
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitEscapeCharacter(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLExists.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLExists.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLExists.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLExists.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLExists extends SimpleNode {
-	public EJBQLExists(int id) {
-		super(id);
-	}
 
-    EJBQLExists(AbstractParser parser, int id) {
+    public EJBQLExists(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitExists(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLFrom.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLFrom.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLFrom.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLFrom.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLFrom(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitFrom(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLFromItem.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLFromItem.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLFromItem.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLFromItem.java Mon Apr  9 02:54:53 2007
@@ -26,24 +26,25 @@
  */
 public class EJBQLFromItem extends SimpleNode {
 
-    private transient AbstractParser parser;
-
     public EJBQLFromItem(int id) {
         super(id);
     }
 
-    EJBQLFromItem(AbstractParser parser, int id) {
-        super(id);
-        this.parser = parser;
-    }
-
-    public void jjtClose() {
-        if (parser != null) {
-            parser.fromItemLoaded(this);
+    public String getId() {
+        int len = getChildrenCount();
+        if (len < 2) {
+            return null;
         }
+
+        return jjtGetChild(len - 1).getText();
     }
 
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
-        return visitor.visitFromItem(this);
+        return visitor.visitFromItem(this, -1);
+    }
+
+    protected boolean visitChild(EJBQLExpressionVisitor visitor, int childIndex) {
+        return super.visitChild(visitor, childIndex)
+                && visitor.visitFromItem(this, childIndex);
     }
 }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGreaterOrEqual.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGreaterOrEqual.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGreaterOrEqual.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGreaterOrEqual.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLGreaterOrEqual(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitGreaterOrEqual(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGreaterThan.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGreaterThan.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGreaterThan.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGreaterThan.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLGreaterThan(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitGreaterThan(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGroupBy.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGroupBy.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGroupBy.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLGroupBy.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLGroupBy extends SimpleNode {
-	public EJBQLGroupBy(int id) {
-		super(id);
-	}
-    
-    EJBQLGroupBy(AbstractParser parser, int id) {
+
+    public EJBQLGroupBy(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitGroupBy(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLHaving.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLHaving.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLHaving.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLHaving.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLHaving extends SimpleNode {
-	public EJBQLHaving(int id) {
-		super(id);
-	}
-    
-    EJBQLHaving(AbstractParser parser, int id) {
+
+    public EJBQLHaving(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitHaving(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIdentificationVariable.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIdentificationVariable.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIdentificationVariable.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIdentificationVariable.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLIdentificationVariable(AbstractParser parser, int id) {
-        super(id);
-    }
-
     public boolean visit(EJBQLExpressionVisitor visitor) {
         return visitor.visitIdentificationVariable(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIdentifier.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIdentifier.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIdentifier.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIdentifier.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLIdentifier(AbstractParser parser, int id) {
-        super(id);
-    }
-
     public boolean visit(EJBQLExpressionVisitor visitor) {
         return visitor.visitIdentifier(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIn.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIn.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIn.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIn.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLIn extends SimpleNode {
-	public EJBQLIn(int id) {
-		super(id);
-	}
-    
-    EJBQLIn(AbstractParser parser, int id) {
+
+    public EJBQLIn(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitIn(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLInnerFetchJoin.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLInnerFetchJoin.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLInnerFetchJoin.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLInnerFetchJoin.java Mon Apr  9 02:54:53 2007
@@ -24,16 +24,18 @@
  * @since 3.0
  * @author Andrus Adamchik
  */
-public class EJBQLInnerFetchJoin extends SimpleNode {
-	public EJBQLInnerFetchJoin(int id) {
-		super(id);
-	}
-    
-    EJBQLInnerFetchJoin(AbstractParser parser, int id) {
+public class EJBQLInnerFetchJoin extends EJBQLJoin {
+
+    public EJBQLInnerFetchJoin(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
-        return visitor.visitInnerFetchJoin(this);
+        return visitor.visitInnerFetchJoin(this, -1);
+    }
+
+    protected boolean visitChild(EJBQLExpressionVisitor visitor, int childIndex) {
+        return super.visitChild(visitor, childIndex)
+                && visitor.visitInnerFetchJoin(this, childIndex);
     }
 }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLInnerJoin.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLInnerJoin.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLInnerJoin.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLInnerJoin.java Mon Apr  9 02:54:53 2007
@@ -24,16 +24,18 @@
  * @since 3.0
  * @author Andrus Adamchik
  */
-public class EJBQLInnerJoin extends SimpleNode {
-	public EJBQLInnerJoin(int id) {
-		super(id);
-	}
-    
-    EJBQLInnerJoin(AbstractParser parser, int id) {
+public class EJBQLInnerJoin extends EJBQLJoin {
+
+    public EJBQLInnerJoin(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
-        return visitor.visitInnerJoin(this);
+        return visitor.visitInnerJoin(this, -1);
+    }
+
+    protected boolean visitChild(EJBQLExpressionVisitor visitor, int childIndex) {
+        return super.visitChild(visitor, childIndex)
+                && visitor.visitInnerJoin(this, childIndex);
     }
 }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIntegerLiteral.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIntegerLiteral.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIntegerLiteral.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIntegerLiteral.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLIntegerLiteral(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitIntegerLiteral(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIsEmpty.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIsEmpty.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIsEmpty.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIsEmpty.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLIsEmpty extends SimpleNode {
-	public EJBQLIsEmpty(int id) {
-		super(id);
-	}
-    
-    EJBQLIsEmpty(AbstractParser parser, int id) {
+
+    public EJBQLIsEmpty(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitIsEmpty(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIsNull.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIsNull.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIsNull.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLIsNull.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLIsNull extends SimpleNode {
-	public EJBQLIsNull(int id) {
-		super(id);
-	}
-    
-    EJBQLIsNull(AbstractParser parser, int id) {
+
+    public EJBQLIsNull(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitIsNull(this);
     }

Added: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLJoin.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLJoin.java?view=auto&rev=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLJoin.java (added)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLJoin.java Mon Apr  9 02:54:53 2007
@@ -0,0 +1,35 @@
+/*****************************************************************
+ *   Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ ****************************************************************/
+package org.apache.cayenne.ejbql.parser;
+
+public class EJBQLJoin extends SimpleNode {
+
+    public EJBQLJoin(int id) {
+        super(id);
+    }
+
+    public String getId() {
+        int len = getChildrenCount();
+        if (len < 2) {
+            return null;
+        }
+
+        return jjtGetChild(len - 1).getText();
+    }
+}

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLength.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLength.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLength.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLength.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLLength extends SimpleNode {
-	public EJBQLLength(int id) {
-		super(id);
-	}
-    
-    EJBQLLength(AbstractParser parser, int id) {
+
+    public EJBQLLength(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitLength(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLessOrEqual.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLessOrEqual.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLessOrEqual.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLessOrEqual.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLLessOrEqual(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitLessOrEqual(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLessThan.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLessThan.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLessThan.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLessThan.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLLessThan(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitLessThan(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLike.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLike.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLike.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLike.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLLike(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitLike(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLocate.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLocate.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLocate.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLocate.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLLocate extends SimpleNode {
-	public EJBQLLocate(int id) {
-		super(id);
-	}
-    
-    EJBQLLocate(AbstractParser parser, int id) {
+
+    public EJBQLLocate(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitLocate(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLower.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLower.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLower.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLLower.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLLower extends SimpleNode {
-	public EJBQLLower(int id) {
-		super(id);
-	}
-    
-    EJBQLLower(AbstractParser parser, int id) {
+
+    public EJBQLLower(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitLower(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMax.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMax.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMax.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMax.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLMax extends SimpleNode {
-	public EJBQLMax(int id) {
-		super(id);
-	}
 
-    EJBQLMax(AbstractParser parser, int id) {
+    public EJBQLMax(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitMax(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMemberOf.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMemberOf.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMemberOf.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMemberOf.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLMemberOf extends SimpleNode {
-	public EJBQLMemberOf(int id) {
-		super(id);
-	}
-    
-    EJBQLMemberOf(AbstractParser parser, int id) {
+
+    public EJBQLMemberOf(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitMemberOf(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMin.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMin.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMin.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMin.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLMin extends SimpleNode {
-	public EJBQLMin(int id) {
-		super(id);
-	}
 
-    EJBQLMin(AbstractParser parser, int id) {
+    public EJBQLMin(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitMin(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMod.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMod.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMod.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMod.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLMod(AbstractParser parser, int id) {
-        super(id);
-    }
-    
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitMod(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMultiply.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMultiply.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMultiply.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLMultiply.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLMultiply(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitMultiply(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNamedInputParameter.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNamedInputParameter.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNamedInputParameter.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNamedInputParameter.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLNamedInputParameter extends SimpleNode {
-	public EJBQLNamedInputParameter(int id) {
-		super(id);
-	}
-    
-    EJBQLNamedInputParameter(AbstractParser parser, int id) {
+
+    public EJBQLNamedInputParameter(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitNamedInputParameter(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNegative.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNegative.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNegative.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNegative.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLNegative extends SimpleNode {
-	public EJBQLNegative(int id) {
-		super(id);
-	}
 
-    EJBQLNegative(AbstractParser parser, int id) {
+    public EJBQLNegative(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitNegative(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNot.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNot.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNot.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNot.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLNot extends SimpleNode {
-	public EJBQLNot(int id) {
-		super(id);
-	}
-    
-    EJBQLNot(AbstractParser parser, int id) {
+
+    public EJBQLNot(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitNot(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNotEquals.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNotEquals.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNotEquals.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLNotEquals.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLNotEquals(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitNotEquals(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOr.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOr.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOr.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOr.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLOr(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitOr(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOrderBy.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOrderBy.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOrderBy.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOrderBy.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLOrderBy extends SimpleNode {
-	public EJBQLOrderBy(int id) {
-		super(id);
-	}
 
-    EJBQLOrderBy(AbstractParser parser, int id) {
+    public EJBQLOrderBy(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitOrderBy(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOrderByItem.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOrderByItem.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOrderByItem.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOrderByItem.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLOrderByItem extends SimpleNode {
-	public EJBQLOrderByItem(int id) {
-		super(id);
-	}
-    
-    EJBQLOrderByItem(AbstractParser parser, int id) {
+
+    public EJBQLOrderByItem(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitOrderByItem(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOuterFetchJoin.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOuterFetchJoin.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOuterFetchJoin.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOuterFetchJoin.java Mon Apr  9 02:54:53 2007
@@ -24,16 +24,18 @@
  * @since 3.0
  * @author Andrus Adamchik
  */
-public class EJBQLOuterFetchJoin extends SimpleNode {
-	public EJBQLOuterFetchJoin(int id) {
-		super(id);
-	}
-    
-    EJBQLOuterFetchJoin(AbstractParser parser, int id) {
+public class EJBQLOuterFetchJoin extends EJBQLJoin {
+
+    public EJBQLOuterFetchJoin(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
-        return visitor.visitOuterFetchJoin(this);
+        return visitor.visitOuterFetchJoin(this, -1);
+    }
+
+    protected boolean visitChild(EJBQLExpressionVisitor visitor, int childIndex) {
+        return super.visitChild(visitor, childIndex)
+                && visitor.visitOuterFetchJoin(this, childIndex);
     }
 }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOuterJoin.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOuterJoin.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOuterJoin.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLOuterJoin.java Mon Apr  9 02:54:53 2007
@@ -24,16 +24,18 @@
  * @since 3.0
  * @author Andrus Adamchik
  */
-public class EJBQLOuterJoin extends SimpleNode {
-	public EJBQLOuterJoin(int id) {
-		super(id);
-	}
-    
-    EJBQLOuterJoin(AbstractParser parser, int id) {
+public class EJBQLOuterJoin extends EJBQLJoin {
+
+    public EJBQLOuterJoin(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
-        return visitor.visitOuterJoin(this);
+        return visitor.visitOuterJoin(this, -1);
+    }
+
+    protected boolean visitChild(EJBQLExpressionVisitor visitor, int childIndex) {
+        return super.visitChild(visitor, childIndex)
+                && visitor.visitOuterJoin(this, childIndex);
     }
 }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPath.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPath.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPath.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPath.java Mon Apr  9 02:54:53 2007
@@ -30,8 +30,36 @@
         super(id);
     }
 
-    EJBQLPath(AbstractParser parser, int id) {
-        super(id);
+    public String getId() {
+        return (getChildrenCount() > 0) ? jjtGetChild(0).getText() : null;
+    }
+
+    public String getRelativePath() {
+        int len = getChildrenCount();
+        if (len < 2) {
+            return null;
+        }
+
+        StringBuffer buffer = new StringBuffer(jjtGetChild(1).getText());
+        for (int i = 2; i < len; i++) {
+            buffer.append('.').append(jjtGetChild(i).getText());
+        }
+
+        return buffer.toString();
+    }
+
+    public String getAbsolutePath() {
+        int len = getChildrenCount();
+        if (len < 1) {
+            return null;
+        }
+
+        StringBuffer buffer = new StringBuffer(jjtGetChild(0).getText());
+        for (int i = 1; i < len; i++) {
+            buffer.append('.').append(jjtGetChild(i).getText());
+        }
+
+        return buffer.toString();
     }
 
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPatternValue.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPatternValue.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPatternValue.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPatternValue.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLPatternValue extends SimpleNode {
-	public EJBQLPatternValue(int id) {
-		super(id);
-	}
-    
-    EJBQLPatternValue(AbstractParser parser, int id) {
+
+    public EJBQLPatternValue(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitPatternValue(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPositionalInputParameter.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPositionalInputParameter.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPositionalInputParameter.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLPositionalInputParameter.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLPositionalInputParameter(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitPositionalInputParameter(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelect.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelect.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelect.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelect.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLSelect(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitSelect(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectClause.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectClause.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectClause.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectClause.java Mon Apr  9 02:54:53 2007
@@ -28,10 +28,6 @@
         super(id);
     }
 
-    EJBQLSelectClause(AbstractParser parser, int id) {
-        super(id);
-    }
-
     // no visitor method for now, as this node is semantical and not important in
     // analyzing the query
 }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectExpression.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectExpression.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectExpression.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectExpression.java Mon Apr  9 02:54:53 2007
@@ -26,19 +26,8 @@
  */
 public class EJBQLSelectExpression extends SimpleNode {
 
-    private transient AbstractParser parser;
-
     public EJBQLSelectExpression(int id) {
         super(id);
-    }
-
-    EJBQLSelectExpression(AbstractParser parser, int id) {
-        super(id);
-        this.parser = parser;
-    }
-
-    public void jjtClose() {
-        parser.selectExpressionLoaded(this);
     }
 
     public boolean visitNode(EJBQLExpressionVisitor visitor) {

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectExpressions.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectExpressions.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectExpressions.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSelectExpressions.java Mon Apr  9 02:54:53 2007
@@ -28,10 +28,6 @@
         super(id);
     }
 
-    EJBQLSelectExpressions(AbstractParser parser, int id) {
-        super(id);
-    }
-
     // no visitor method for now, as this node is semantical and not important in
     // analyzing the query
 }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSize.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSize.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSize.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSize.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLSize extends SimpleNode {
-	public EJBQLSize(int id) {
-		super(id);
-	}
-    
-    EJBQLSize(AbstractParser parser, int id) {
+
+    public EJBQLSize(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitSize(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSqrt.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSqrt.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSqrt.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSqrt.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLSqrt extends SimpleNode {
-	public EJBQLSqrt(int id) {
-		super(id);
-	}
-    
-    EJBQLSqrt(AbstractParser parser, int id) {
+
+    public EJBQLSqrt(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitSqrt(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLStringLiteral.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLStringLiteral.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLStringLiteral.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLStringLiteral.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLStringLiteral extends SimpleNode {
-	public EJBQLStringLiteral(int id) {
-		super(id);
-	}
-    
-    EJBQLStringLiteral(AbstractParser parser, int id) {
+
+    public EJBQLStringLiteral(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitStringLiteral(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubselect.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubselect.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubselect.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubselect.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLSubselect(AbstractParser parser, int id) {
-        super(id);
-    }
-    
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitSubselect(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubstring.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubstring.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubstring.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubstring.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLSubstring extends SimpleNode {
-	public EJBQLSubstring(int id) {
-		super(id);
-	}
 
-    EJBQLSubstring(AbstractParser parser, int id) {
+    public EJBQLSubstring(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitSubstring(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubtract.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubtract.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubtract.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSubtract.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLSubtract(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitSubtract(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSum.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSum.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSum.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLSum.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLSum extends SimpleNode {
-	public EJBQLSum(int id) {
-		super(id);
-	}
-    
-    EJBQLSum(AbstractParser parser, int id) {
+
+    public EJBQLSum(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitSum(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTok.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTok.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTok.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTok.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLTok extends SimpleNode {
-	public EJBQLTok(int id) {
-		super(id);
-	}
 
-    EJBQLTok(AbstractParser parser, int id) {
+    public EJBQLTok(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitTok(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrim.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrim.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrim.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrim.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLTrim extends SimpleNode {
-	public EJBQLTrim(int id) {
-		super(id);
-	}
-    
-    EJBQLTrim(AbstractParser parser, int id) {
+
+    public EJBQLTrim(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitTrim(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimBoth.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimBoth.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimBoth.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimBoth.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLTrimBoth(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitTrimBoth(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimCharacter.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimCharacter.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimCharacter.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimCharacter.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLTrimCharacter extends SimpleNode {
-	public EJBQLTrimCharacter(int id) {
-		super(id);
-	}
-    
-    EJBQLTrimCharacter(AbstractParser parser, int id) {
+
+    public EJBQLTrimCharacter(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitTrimCharacter(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimLeading.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimLeading.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimLeading.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimLeading.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLTrimLeading extends SimpleNode {
-	public EJBQLTrimLeading(int id) {
-		super(id);
-	}
-    
-    EJBQLTrimLeading(AbstractParser parser, int id) {
+
+    public EJBQLTrimLeading(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitTrimLeading(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimTrailing.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimTrailing.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimTrailing.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLTrimTrailing.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLTrimTrailing extends SimpleNode {
-	public EJBQLTrimTrailing(int id) {
-		super(id);
-	}
-    
-    EJBQLTrimTrailing(AbstractParser parser, int id) {
+
+    public EJBQLTrimTrailing(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitTrimTrailing(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdate.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdate.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdate.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdate.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLUpdate(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitUpdate(this, -1);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateField.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateField.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateField.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateField.java Mon Apr  9 02:54:53 2007
@@ -28,11 +28,7 @@
 	public EJBQLUpdateField(int id) {
 		super(id);
 	}
-    
-    EJBQLUpdateField(AbstractParser parser, int id) {
-        super(id);
-    }
-    
+   
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitUpdateField(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateItem.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateItem.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateItem.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateItem.java Mon Apr  9 02:54:53 2007
@@ -30,10 +30,6 @@
         super(id);
     }
 
-    EJBQLUpdateItem(AbstractParser parser, int id) {
-        super(id);
-    }
-
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitUpdateItem(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateValue.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateValue.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateValue.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpdateValue.java Mon Apr  9 02:54:53 2007
@@ -25,14 +25,11 @@
  * @author Andrus Adamchik
  */
 public class EJBQLUpdateValue extends SimpleNode {
-	public EJBQLUpdateValue(int id) {
-		super(id);
-	}
-    
-    EJBQLUpdateValue(AbstractParser parser, int id) {
+
+    public EJBQLUpdateValue(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitUpdateValue(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpper.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpper.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpper.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLUpper.java Mon Apr  9 02:54:53 2007
@@ -26,14 +26,10 @@
  */
 public class EJBQLUpper extends SimpleNode {
 
-	public EJBQLUpper(int id) {
-		super(id);
-	}
-    
-    EJBQLUpper(AbstractParser parser, int id) {
+    public EJBQLUpper(int id) {
         super(id);
     }
-    
+
     protected boolean visitNode(EJBQLExpressionVisitor visitor) {
         return visitor.visitUpper(this);
     }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLWhere.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLWhere.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLWhere.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/ejbql/parser/EJBQLWhere.java Mon Apr  9 02:54:53 2007
@@ -30,11 +30,12 @@
         super(id);
     }
 
-    EJBQLWhere(AbstractParser parser, int id) {
-        super(id);
+    protected boolean visitNode(EJBQLExpressionVisitor visitor) {
+        return visitor.visitWhere(this, -1);
     }
 
-    protected boolean visitNode(EJBQLExpressionVisitor visitor) {
-        return visitor.visitWhere(this);
+    protected boolean visitChild(EJBQLExpressionVisitor visitor, int childIndex) {
+        return super.visitChild(visitor, childIndex)
+                && visitor.visitWhere(this, childIndex);
     }
 }

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/jjtree/org/apache/cayenne/ejbql/EJBQLParser.jjt
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/jjtree/org/apache/cayenne/ejbql/EJBQLParser.jjt?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/jjtree/org/apache/cayenne/ejbql/EJBQLParser.jjt (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/jjtree/org/apache/cayenne/ejbql/EJBQLParser.jjt Mon Apr  9 02:54:53 2007
@@ -29,7 +29,7 @@
 	NODE_DEFAULT_VOID = true;
 	JAVA_UNICODE_ESCAPE = true;
 	STATIC = false;
-	NODE_USES_PARSER = true;
+	NODE_USES_PARSER = false;
 
 	LOOKAHEAD = 1;
 
@@ -51,25 +51,12 @@
 import org.apache.cayenne.ejbql.*;
 import org.apache.cayenne.map.*;
 
-public class EJBQL extends AbstractParser {
+public class EJBQL {
 
 	public EJBQL (String source) {
 		this (new StringReader (source));
-		this.source = source;
 	}
 	
-	EJBQLCompiledExpression compileQuery(EntityResolver resolver) throws ParseException {
-        this.descriptorsById = new HashMap();
-        this.resolver = resolver;
-
-        CompiledExpression compiled = new CompiledExpression();
-        compiled.setExpression(parseQuery());
-        compiled.setDescriptorsById(descriptorsById);
-        compiled.setSource(source);
-        compiled.setRootId(rootId);
-        return compiled;
-    }
-	
     public static class EJBQLDefaultParser implements EJBQLParser {
 
        public EJBQLExpression parse(String ejbqlStatement) throws EJBQLException {
@@ -83,7 +70,7 @@
        
        public EJBQLCompiledExpression compile(String ejbqlStatement, EntityResolver resolver) throws EJBQLException {
            try {
-              return new EJBQL(ejbqlStatement).compileQuery(resolver);
+              return new Compiler(resolver).compile(ejbqlStatement, new EJBQL(ejbqlStatement).parseQuery());
            }
            catch(ParseException e) {
               throw new EJBQLException("Error parsing EJB QL statement", e);

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/test/java/org/apache/cayenne/access/DataContextEJBQLJoinsTest.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/test/java/org/apache/cayenne/access/DataContextEJBQLJoinsTest.java?view=diff&rev=526696&r1=526695&r2=526696
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/test/java/org/apache/cayenne/access/DataContextEJBQLJoinsTest.java (original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/test/java/org/apache/cayenne/access/DataContextEJBQLJoinsTest.java Mon Apr  9 02:54:53 2007
@@ -18,6 +18,14 @@
  ****************************************************************/
 package org.apache.cayenne.access;
 
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+
+import org.apache.art.Artist;
+import org.apache.cayenne.DataObjectUtils;
+import org.apache.cayenne.query.EJBQLQuery;
 import org.apache.cayenne.unit.CayenneCase;
 
 public class DataContextEJBQLJoinsTest extends CayenneCase {
@@ -33,7 +41,11 @@
         // + "FROM Artist a, Painting b "
         // + "WHERE a.artistName = b.paintingTitle";
         //
-        // List artists = createDataContext().performQuery(new EJBQLQuery(ejbql));
+        // EJBQLQuery query = new EJBQLQuery(ejbql);
+        //
+        // System.out.println(""
+        // + query.getExpression(getDomain().getEntityResolver()).getExpression());
+        // List artists = createDataContext().performQuery(query);
         // assertEquals(2, artists.size());
         //
         // Set names = new HashSet(2);
@@ -50,44 +62,48 @@
     public void testInnerJoins() throws Exception {
         createTestData("testInnerJoins");
 
-        // String ejbql = "SELECT a "
-        // + "FROM Artist a INNER JOIN a.paintingArray p "
-        // + "WHERE a.artistName = 'A1'";
-        //
-        // List artists = createDataContext().performQuery(new EJBQLQuery(ejbql));
-        // assertEquals(1, artists.size());
-        // assertEquals(33001, DataObjectUtils.intPKForObject((Artist) artists.get(0)));
+        String ejbql = "SELECT a "
+                + "FROM Artist a INNER JOIN a.paintingArray p "
+                + "WHERE a.artistName = 'AA1'";
+
+        List artists = createDataContext().performQuery(new EJBQLQuery(ejbql));
+        assertEquals(1, artists.size());
+        assertEquals(33001, DataObjectUtils.intPKForObject((Artist) artists.get(0)));
     }
 
     public void testOuterJoins() throws Exception {
         createTestData("testInnerJoins");
 
-        // String ejbql = "SELECT a "
-        // + "FROM Artist a LEFT JOIN a.paintingArray p "
-        // + "WHERE a.artistName = 'A1'";
-        //
-        // List artists = createDataContext().performQuery(new EJBQLQuery(ejbql));
-        // assertEquals(2, artists.size());
-        // Set ids = new HashSet(2);
-        // Iterator it = artists.iterator();
-        // while (it.hasNext()) {
-        // Artist a = (Artist) it.next();
-        // ids.add(DataObjectUtils.pkForObject(a));
-        // }
-        //
-        // assertTrue(ids.contains(new Integer(33001)));
-        // assertTrue(ids.contains(new Integer(33005)));
+         String ejbql = "SELECT a "
+                + "FROM Artist a LEFT JOIN a.paintingArray p "
+                + "WHERE a.artistName = 'AA1'";
+
+        List artists = createDataContext().performQuery(new EJBQLQuery(ejbql));
+        assertEquals(2, artists.size());
+        Set ids = new HashSet(2);
+        Iterator it = artists.iterator();
+        while (it.hasNext()) {
+            Artist a = (Artist) it.next();
+            ids.add(DataObjectUtils.pkForObject(a));
+        }
+
+        assertTrue(ids.contains(new Integer(33001)));
+        assertTrue(ids.contains(new Integer(33005)));
     }
 
     public void testChainedJoins() throws Exception {
         createTestData("testChainedJoins");
-        // String ejbql = "SELECT a "
-        // + "FROM Artist a JOIN a.paintingArray p JOIN p.toGallery g "
-        // + "WHERE g.galleryName = 'gallery2'";
-        //
-        // List artists = createDataContext().performQuery(new EJBQLQuery(ejbql));
-        // assertEquals(1, artists.size());
-        // assertEquals(33002, DataObjectUtils.intPKForObject((Artist) artists.get(0)));
+        String ejbql = "SELECT a "
+                + "FROM Artist a JOIN a.paintingArray p JOIN p.toGallery g "
+                + "WHERE g.galleryName = 'gallery2'";
+
+        EJBQLQuery query = new EJBQLQuery(ejbql);
+
+        System.out.println(""
+                + query.getExpression(getDomain().getEntityResolver()).getExpression());
+        List artists = createDataContext().performQuery(query);
+        assertEquals(1, artists.size());
+        assertEquals(33002, DataObjectUtils.intPKForObject((Artist) artists.get(0)));
     }
 
     public void testImplicitJoins() throws Exception {
@@ -120,6 +136,6 @@
         //
         // List artists = createDataContext().performQuery(new EJBQLQuery(ejbql));
         // assertEquals(1, artists.size());
-        //        assertEquals(33001, DataObjectUtils.intPKForObject((Artist) artists.get(0)));
+        // assertEquals(33001, DataObjectUtils.intPKForObject((Artist) artists.get(0)));
     }
 }



Mime
View raw message