jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From resc...@apache.org
Subject svn commit: r770286 - in /jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query: jsr283/ qom/QueryObjectModelFactoryImpl.java sql2/Parser.java
Date Thu, 30 Apr 2009 15:31:30 GMT
Author: reschke
Date: Thu Apr 30 15:31:29 2009
New Revision: 770286

URL: http://svn.apache.org/viewvc?rev=770286&view=rev
Log:
JCR-2092: remove custom QOMFactory interface; note that a few methods are gone, adjusted the
code to pass null where additional parameters were required, marked those places as TODO.

Removed:
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/jsr283/
Modified:
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/qom/QueryObjectModelFactoryImpl.java
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/sql2/Parser.java

Modified: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/qom/QueryObjectModelFactoryImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/qom/QueryObjectModelFactoryImpl.java?rev=770286&r1=770285&r2=770286&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/qom/QueryObjectModelFactoryImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/qom/QueryObjectModelFactoryImpl.java
Thu Apr 30 15:31:29 2009
@@ -21,8 +21,6 @@
 import org.apache.jackrabbit.spi.commons.conversion.NameException;
 import org.apache.jackrabbit.spi.Path;
 
-import org.apache.jackrabbit.spi.commons.query.jsr283.qom.QueryObjectModelFactory;
-
 import javax.jcr.query.InvalidQueryException;
 import javax.jcr.query.qom.And;
 import javax.jcr.query.qom.BindVariableValue;
@@ -51,6 +49,7 @@
 import javax.jcr.query.qom.PropertyValue;
 import javax.jcr.query.qom.QueryObjectModel;
 import javax.jcr.query.qom.QueryObjectModelConstants;
+import javax.jcr.query.qom.QueryObjectModelFactory;
 import javax.jcr.query.qom.SameNode;
 import javax.jcr.query.qom.SameNodeJoinCondition;
 import javax.jcr.query.qom.Selector;

Modified: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/sql2/Parser.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/sql2/Parser.java?rev=770286&r1=770285&r2=770286&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/sql2/Parser.java
(original)
+++ jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/query/sql2/Parser.java
Thu Apr 30 15:31:29 2009
@@ -16,8 +16,6 @@
  */
 package org.apache.jackrabbit.spi.commons.query.sql2;
 
-import org.apache.jackrabbit.spi.commons.query.jsr283.qom.QueryObjectModelFactory;
-
 import java.math.BigDecimal;
 import java.util.ArrayList;
 import java.util.HashMap;
@@ -38,6 +36,7 @@
 import javax.jcr.query.qom.PropertyValue;
 import javax.jcr.query.qom.QueryObjectModel;
 import javax.jcr.query.qom.QueryObjectModelConstants;
+import javax.jcr.query.qom.QueryObjectModelFactory;
 import javax.jcr.query.qom.Selector;
 import javax.jcr.query.qom.Source;
 import javax.jcr.query.qom.StaticOperand;
@@ -130,7 +129,7 @@
             String selectorName = readName();
             return factory.selector(nodeTypeName, selectorName);
         } else {
-            return factory.selector(nodeTypeName);
+            return factory.selector(nodeTypeName, null /* TODO */);
         }
     }
 
@@ -203,7 +202,7 @@
                 if (readIf(",")) {
                     c = factory.sameNodeJoinCondition(selector1, selector2, readPath());
                 } else {
-                    c = factory.sameNodeJoinCondition(selector1, selector2);
+                    c = factory.sameNodeJoinCondition(selector1, selector2, null /* TODO
*/);
                 }
             } else if ("ISCHILDNODE".equals(name)) {
                 String childSelector = readName();
@@ -265,7 +264,7 @@
             } else if (readIf(".")) {
                 a = parseCondition(factory.propertyValue(identifier, readName()));
             } else {
-                a = parseCondition(factory.propertyValue(identifier));
+                a = parseCondition(factory.propertyValue(identifier, null /* TODO */));
             }
         } else {
             throw getSyntaxError();
@@ -341,7 +340,7 @@
 
     private PropertyExistence getPropertyExistence(PropertyValue p) throws InvalidQueryException,
RepositoryException {
         if (p.getSelectorName() == null) {
-            return factory.propertyExistence(p.getPropertyName());
+            return factory.propertyExistence(p.getPropertyName(), null /* TODO */);
         } else {
             return factory.propertyExistence(p.getSelectorName(), p.getPropertyName());
         }
@@ -364,28 +363,28 @@
                 }
             } else {
                 read(",");
-                c = factory.fullTextSearch(name, readString());
+                c = factory.fullTextSearch(name, readString(), null /* TODO */);
             }
         } else if ("ISSAMENODE".equals(functionName)) {
             String name = readName();
             if (readIf(",")) {
                 c = factory.sameNode(name, readPath());
             } else {
-                c = factory.sameNode(name);
+                c = factory.sameNode(name, null /* TODO */);
             }
         } else if ("ISCHILDNODE".equals(functionName)) {
             String name = readName();
             if (readIf(",")) {
                 c = factory.childNode(name, readPath());
             } else {
-                c = factory.childNode(name);
+                c = factory.childNode(name, null /* TODO */);
             }
         } else if ("ISDESCENDANTNODE".equals(functionName)) {
             String name = readName();
             if (readIf(",")) {
                 c = factory.descendantNode(name, readPath());
             } else {
-                c = factory.descendantNode(name);
+                c = factory.descendantNode(name, null /* TODO */);
             }
         } else {
             return null;
@@ -416,19 +415,19 @@
             op = factory.length(parsePropertyValue(readName()));
         } else if ("NAME".equals(functionName)) {
             if (isToken(")")) {
-                op = factory.nodeName();
+                op = factory.nodeName(null /* TODO */);
             } else {
                 op = factory.nodeName(readName());
             }
         } else if ("LOCALNAME".equals(functionName)) {
             if (isToken(")")) {
-                op = factory.nodeLocalName();
+                op = factory.nodeLocalName(null /* TODO */);
             } else {
                 op = factory.nodeLocalName(readName());
             }
         } else if ("SCORE".equals(functionName)) {
             if (isToken(")")) {
-                op = factory.fullTextSearchScore();
+                op = factory.fullTextSearchScore(null /* TODO */);
             } else {
                 op = factory.fullTextSearchScore(readName());
             }
@@ -448,7 +447,7 @@
         if (readIf(".")) {
             return factory.propertyValue(name, readName());
         } else {
-            return factory.propertyValue(name);
+            return factory.propertyValue(name, null /* TODO */);
         }
     }
 
@@ -563,9 +562,9 @@
                 if (c.selectorName != null) {
                     column = factory.column(c.selectorName, c.propertyName, c.columnName);
                 } else if (c.columnName != null) {
-                    column = factory.column(c.propertyName, c.columnName);
+                    column = factory.column(c.propertyName, c.columnName, null /* TODO */);
                 } else {
-                    column = factory.column(c.propertyName);
+                    column = factory.column(c.propertyName, null /* TODO */, null /* TODO
*/);
                 }
                 columns.add(column);
             }



Mime
View raw message