jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thom...@apache.org
Subject svn commit: r1373282 - in /jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr: SessionDelegate.java query/QueryManagerImpl.java
Date Wed, 15 Aug 2012 09:22:02 GMT
Author: thomasm
Date: Wed Aug 15 09:22:01 2012
New Revision: 1373282

URL: http://svn.apache.org/viewvc?rev=1373282&view=rev
Log:
OAK-241 QueryEngine.executeQuery needs a session parameter (partial)

Modified:
    jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java
    jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/query/QueryManagerImpl.java

Modified: jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java?rev=1373282&r1=1373281&r2=1373282&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java
(original)
+++ jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java
Wed Aug 15 09:22:01 2012
@@ -39,7 +39,7 @@ import org.apache.jackrabbit.oak.api.Cha
 import org.apache.jackrabbit.oak.api.CommitFailedException;
 import org.apache.jackrabbit.oak.api.ConflictHandler;
 import org.apache.jackrabbit.oak.api.ContentSession;
-import org.apache.jackrabbit.oak.api.QueryEngine;
+import org.apache.jackrabbit.oak.api.SessionQueryEngine;
 import org.apache.jackrabbit.oak.api.Root;
 import org.apache.jackrabbit.oak.api.Tree;
 import org.apache.jackrabbit.oak.commons.PathUtils;
@@ -396,7 +396,7 @@ public class SessionDelegate {
     }
 
     @Nonnull
-    public QueryEngine getQueryEngine() {
+    public SessionQueryEngine getQueryEngine() {
         return contentSession.getQueryEngine();
     }
 

Modified: jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/query/QueryManagerImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/query/QueryManagerImpl.java?rev=1373282&r1=1373281&r2=1373282&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/query/QueryManagerImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/query/QueryManagerImpl.java
Wed Aug 15 09:22:01 2012
@@ -33,9 +33,8 @@ import javax.jcr.query.Query;
 import javax.jcr.query.QueryManager;
 import javax.jcr.query.QueryResult;
 import javax.jcr.query.qom.QueryObjectModelFactory;
-import org.apache.jackrabbit.oak.api.ContentSession;
 import org.apache.jackrabbit.oak.api.CoreValue;
-import org.apache.jackrabbit.oak.api.QueryEngine;
+import org.apache.jackrabbit.oak.api.SessionQueryEngine;
 import org.apache.jackrabbit.oak.api.Result;
 import org.apache.jackrabbit.oak.jcr.SessionDelegate;
 import org.apache.jackrabbit.oak.jcr.query.qom.QueryObjectModelFactoryImpl;
@@ -47,7 +46,7 @@ import org.apache.jackrabbit.oak.namepat
 public class QueryManagerImpl implements QueryManager {
 
     private final QueryObjectModelFactoryImpl qomFactory;
-    private final QueryEngine queryEngine;
+    private final SessionQueryEngine queryEngine;
     private final SessionDelegate sessionDelegate;
     private final HashSet<String> supportedQueryLanguages = new HashSet<String>();
 
@@ -105,9 +104,8 @@ public class QueryManagerImpl implements
             long limit, long offset, HashMap<String, Value> bindVariableMap) throws
RepositoryException {
         try {
             HashMap<String, CoreValue> bindMap = convertMap(bindVariableMap);
-            ContentSession s = sessionDelegate.getContentSession();
             NamePathMapper namePathMapper = sessionDelegate.getNamePathMapper();
-            Result r = queryEngine.executeQuery(statement, language, s, limit, offset, bindMap,
namePathMapper);
+            Result r = queryEngine.executeQuery(statement, language, limit, offset, bindMap,
namePathMapper);
             return new QueryResultImpl(sessionDelegate, r);
         } catch (IllegalArgumentException e) {
             throw new InvalidQueryException(e);



Mime
View raw message