jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thom...@apache.org
Subject svn commit: r1384309 - /jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/spi/query/Cursor.java
Date Thu, 13 Sep 2012 12:44:53 GMT
Author: thomasm
Date: Thu Sep 13 12:44:52 2012
New Revision: 1384309

URL: http://svn.apache.org/viewvc?rev=1384309&view=rev
Log:
OAK-34 Define query API (javadocs)

Modified:
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/spi/query/Cursor.java

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/spi/query/Cursor.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/spi/query/Cursor.java?rev=1384309&r1=1384308&r2=1384309&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/spi/query/Cursor.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/spi/query/Cursor.java
Thu Sep 13 12:44:52 2012
@@ -31,11 +31,26 @@ public interface Cursor {
     boolean next();
 
     /**
-     * The current row within this index. The row usually only contains the
-     * path, but it may additionally contain so-called 'pseudo-properties' such
-     * as "jcr:score" and "rep:excerpt", in case the index supports those
-     * properties and if the properties were requested when running the query.
-     *
+     * The current row within this index.
+     * <p>
+     * The row may only contains the path, if a path is available. It may also
+     * (or just) contain so-called "pseudo-properties" such as "jcr:score" and
+     * "rep:excerpt", in case the index supports those properties and if the
+     * properties were requested when running the query. The query engine will
+     * indicate that those pseudo properties were requested by setting an
+     * appropriate (possibly unrestricted) filter condition.
+     * <p>
+     * The index should return a row with those properties that are stored in
+     * the index itself, so that the query engine doesn't have to load the whole
+     * row / node unnecessarily (avoiding to load the whole row is sometimes
+     * called "index only scan"), specially for rows that are anyway skipped. If
+     * the index does not have an (efficient) way to return some (or any) of the
+     * properties, it doesn't have to provide those values. In this case, the
+     * query engine will load the node itself if required. If all conditions
+     * match, the query engine will sometimes load the node to do access checks,
+     * but this is not always the case, and it is not the case if any of the
+     * (join) conditions do not match.
+     * 
      * @return the row
      */
     IndexRow currentRow();



Mime
View raw message