You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ibatis.apache.org by cb...@apache.org on 2009/10/10 07:18:39 UTC

svn commit: r823792 - in /ibatis/java/ibatis-3/trunk: ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/builder/ ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/impl/ ibatis-3-core/src/main/java/org/apache/ibatis/binding/ ibatis-3-core/src/...

Author: cbegin
Date: Sat Oct 10 05:18:38 2009
New Revision: 823792

URL: http://svn.apache.org/viewvc?rev=823792&view=rev
Log:
renamed rowlimit to RowBounds

Added:
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowBounds.java
      - copied, changed from r822575, ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowLimit.java
Removed:
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowLimit.java
Modified:
    ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/builder/FlushCacheInterceptor.java
    ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/impl/SqlMapSessionImpl.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/binding/MapperMethod.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BaseExecutor.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BatchExecutor.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/CachingExecutor.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/Executor.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/ReuseExecutor.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/SimpleExecutor.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/keygen/SelectKeyGenerator.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/loader/ResultLoader.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/DefaultResultSetHandler.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/BaseStatementHandler.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/CallableStatementHandler.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/PreparedStatementHandler.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/RoutingStatementHandler.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/SimpleStatementHandler.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/mapping/Configuration.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/SqlSession.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/defaults/DefaultSqlSession.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/domain/blog/mappers/BlogMapper.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BindingTest.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BoundAuthorMapper.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/executor/BaseExecutorTest.java
    ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/session/SqlSessionTest.java

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/builder/FlushCacheInterceptor.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/builder/FlushCacheInterceptor.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/builder/FlushCacheInterceptor.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/builder/FlushCacheInterceptor.java Sat Oct 10 05:18:38 2009
@@ -2,7 +2,7 @@
 
 import org.apache.ibatis.cache.Cache;
 import org.apache.ibatis.executor.Executor;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.mapping.MappedStatement;
 import org.apache.ibatis.plugin.*;
@@ -11,7 +11,7 @@
 
 @Intercepts({
   @Signature(type = Executor.class, method = "update", args = {MappedStatement.class, Object.class}),
-  @Signature(type = Executor.class, method = "query", args = {MappedStatement.class, Object.class, RowLimit.class, ResultHandler.class})
+  @Signature(type = Executor.class, method = "query", args = {MappedStatement.class, Object.class, RowBounds.class, ResultHandler.class})
     })
 public class FlushCacheInterceptor implements Interceptor {
 

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/impl/SqlMapSessionImpl.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/impl/SqlMapSessionImpl.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/impl/SqlMapSessionImpl.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-compat/src/main/java/com/ibatis/sqlmap/engine/impl/SqlMapSessionImpl.java Sat Oct 10 05:18:38 2009
@@ -14,7 +14,7 @@
 import org.apache.ibatis.executor.BatchExecutorException;
 import org.apache.ibatis.executor.BatchResult;
 import org.apache.ibatis.executor.Executor;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.executor.result.*;
 import org.apache.ibatis.mapping.MappedStatement;
 import org.apache.ibatis.mapping.ResultMap;
@@ -117,7 +117,7 @@
       public Object execute(Transaction transaction) throws SQLException {
         MappedStatement ms = configuration.getMappedStatement(id);
         Executor executor = transaction.getExecutor();
-        List list = executor.query(ms, wrapCollection(parameterObject), RowLimit.DEFAULT, null);
+        List list = executor.query(ms, wrapCollection(parameterObject), RowBounds.DEFAULT, null);
         if (list.size() == 1) {
           return list.get(0);
         } else if (list.size() > 1) {
@@ -134,13 +134,13 @@
       public Object execute(Transaction transaction) throws SQLException {
         Executor executor = transaction.getExecutor();
         MappedStatement ms = configuration.getMappedStatement(id);
-        return executor.query(ms, wrapCollection(parameterObject), new RowLimit(skip, max), null);
+        return executor.query(ms, wrapCollection(parameterObject), new RowBounds(skip, max), null);
       }
     });
   }
 
   public List queryForList(String id, Object parameterObject) throws SQLException {
-    return queryForList(id, parameterObject, RowLimit.NO_ROW_OFFSET, RowLimit.NO_ROW_LIMIT);
+    return queryForList(id, parameterObject, RowBounds.NO_ROW_OFFSET, RowBounds.NO_ROW_LIMIT);
   }
 
   public List queryForList(String id, int skip, int max) throws SQLException {
@@ -169,7 +169,7 @@
       public Object execute(Transaction transaction) throws SQLException {
         MappedStatement ms = configuration.getMappedStatement(id);
         Executor executor = transaction.getExecutor();
-        return executor.query(ms, wrapCollection(parameterObject), RowLimit.DEFAULT, new ResultHandler() {
+        return executor.query(ms, wrapCollection(parameterObject), RowBounds.DEFAULT, new ResultHandler() {
           public void handleResult(ResultContext context) {
             rowHandler.handleRow(context.getResultObject());
           }
@@ -292,7 +292,7 @@
         public Object execute(Transaction transaction) throws SQLException {
           transaction.setCommitRequired(true);
           Executor executor = transaction.getExecutor();
-          return executor.query(keyStatement, parameterObject, RowLimit.DEFAULT, null);
+          return executor.query(keyStatement, parameterObject, RowBounds.DEFAULT, null);
         }
       });
       try {

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/binding/MapperMethod.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/binding/MapperMethod.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/binding/MapperMethod.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/binding/MapperMethod.java Sat Oct 10 05:18:38 2009
@@ -1,6 +1,6 @@
 package org.apache.ibatis.binding;
 
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.*;
 import org.apache.ibatis.session.SqlSession;
 import org.apache.ibatis.annotations.Param;
@@ -24,7 +24,7 @@
 
   private boolean returnsList;
 
-  private Integer rowLimitIndex;
+  private Integer rowBoundsIndex;
   private List<String> paramNames;
   private List<Integer> paramPositions;
 
@@ -66,10 +66,10 @@
 
   private Object executeForList(Object[] args) throws SQLException {
     Object result;
-    if (rowLimitIndex != null) {
+    if (rowBoundsIndex != null) {
       Object param = getParam(args);
-      RowLimit rowLimit = (RowLimit) args[rowLimitIndex];
-      result = sqlSession.selectList(commandName, param, rowLimit);
+      RowBounds rowBounds = (RowBounds) args[rowBoundsIndex];
+      result = sqlSession.selectList(commandName, param, rowBounds);
     } else {
       Object param = getParam(args);
       result = sqlSession.selectList(commandName, param);
@@ -104,8 +104,8 @@
     }
     final Class[] argTypes = method.getParameterTypes();
     for (int i=0; i < argTypes.length; i++) {
-      if (RowLimit.class.isAssignableFrom(argTypes[i])) {
-        rowLimitIndex = i;
+      if (RowBounds.class.isAssignableFrom(argTypes[i])) {
+        rowBoundsIndex = i;
       } else {
         String paramName = String.valueOf(paramPositions.size());
         paramName = getParamNameFromAnnotation(i, paramName);

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BaseExecutor.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BaseExecutor.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BaseExecutor.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BaseExecutor.java Sat Oct 10 05:18:38 2009
@@ -8,7 +8,7 @@
 import org.apache.ibatis.transaction.Transaction;
 import org.apache.ibatis.type.TypeHandlerRegistry;
 import static org.apache.ibatis.executor.ExecutionPlaceholder.*;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 
 import java.sql.*;
 import java.util.*;
@@ -65,18 +65,18 @@
     return batchResults;
   }
 
-  public List query(MappedStatement ms, Object parameter, RowLimit rowLimit, ResultHandler resultHandler) throws SQLException {
+  public List query(MappedStatement ms, Object parameter, RowBounds rowBounds, ResultHandler resultHandler) throws SQLException {
     ErrorContext.instance().resource(ms.getResource()).activity("executing a query").object(ms.getId());
     List list;
     try {
       queryStack++;
-      CacheKey key = createCacheKey(ms, parameter, rowLimit);
+      CacheKey key = createCacheKey(ms, parameter, rowBounds);
       if (localCache.hasKey(key)) {
         list = (List) localCache.getObject(key);
       } else {
         localCache.putObject(key, EXECUTION_PLACEHOLDER);
         try {
-          list = doQuery(ms, parameter, rowLimit, resultHandler);
+          list = doQuery(ms, parameter, rowBounds, resultHandler);
         } finally {
           localCache.removeObject(key);
         }
@@ -97,12 +97,12 @@
     deferredLoads.add(new DeferredLoad(ms, resultObject, property, key));
   }
 
-  public CacheKey createCacheKey(MappedStatement ms, Object parameterObject, RowLimit rowLimit) {
+  public CacheKey createCacheKey(MappedStatement ms, Object parameterObject, RowBounds rowBounds) {
     BoundSql boundSql = ms.getBoundSql(parameterObject);
     CacheKey cacheKey = new CacheKey();
     cacheKey.update(ms.getId());
-    cacheKey.update(rowLimit.getOffset());
-    cacheKey.update(rowLimit.getLimit());
+    cacheKey.update(rowBounds.getOffset());
+    cacheKey.update(rowBounds.getLimit());
     cacheKey.update(boundSql.getSql());
     List<ParameterMapping> parameterMappings = boundSql.getParameterMappings();
     if (parameterMappings.size() > 0 && parameterObject != null) {
@@ -154,7 +154,7 @@
   protected abstract List<BatchResult> doFlushStatements()
       throws SQLException;
 
-  protected abstract List doQuery(MappedStatement ms, Object parameter, RowLimit rowLimit, ResultHandler resultHandler)
+  protected abstract List doQuery(MappedStatement ms, Object parameter, RowBounds rowBounds, ResultHandler resultHandler)
       throws SQLException;
 
   protected void closeStatement(Statement statement) {

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BatchExecutor.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BatchExecutor.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BatchExecutor.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/BatchExecutor.java Sat Oct 10 05:18:38 2009
@@ -3,7 +3,7 @@
 import org.apache.ibatis.executor.keygen.*;
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.executor.statement.StatementHandler;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.*;
 import org.apache.ibatis.transaction.Transaction;
 
@@ -25,7 +25,7 @@
   public int doUpdate(MappedStatement ms, Object parameterObject)
       throws SQLException {
     Configuration configuration = ms.getConfiguration();
-    StatementHandler handler = configuration.newStatementHandler(this, ms, parameterObject, RowLimit.DEFAULT, null);
+    StatementHandler handler = configuration.newStatementHandler(this, ms, parameterObject, RowBounds.DEFAULT, null);
     BoundSql boundSql = handler.getBoundSql();
     String sql = boundSql.getSql();
     Statement stmt;
@@ -44,11 +44,11 @@
     return BATCH_UPDATE_RETURN_VALUE;
   }
 
-  public List doQuery(MappedStatement ms, Object parameterObject, RowLimit rowLimit, ResultHandler resultHandler)
+  public List doQuery(MappedStatement ms, Object parameterObject, RowBounds rowBounds, ResultHandler resultHandler)
       throws SQLException {
     flushStatements();
     Configuration configuration = ms.getConfiguration();
-    StatementHandler handler = configuration.newStatementHandler(this, ms, parameterObject, rowLimit, resultHandler);
+    StatementHandler handler = configuration.newStatementHandler(this, ms, parameterObject, rowBounds, resultHandler);
     Connection connection = transaction.getConnection();
     Statement stmt = handler.prepare(connection);
     handler.parameterize(stmt);

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/CachingExecutor.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/CachingExecutor.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/CachingExecutor.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/CachingExecutor.java Sat Oct 10 05:18:38 2009
@@ -2,7 +2,7 @@
 
 import org.apache.ibatis.cache.*;
 import org.apache.ibatis.executor.result.ResultHandler;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.MappedStatement;
 import org.apache.ibatis.reflection.MetaObject;
 import org.apache.ibatis.transaction.Transaction;
@@ -38,7 +38,7 @@
   }
 
 
-  public List query(MappedStatement ms, Object parameterObject, RowLimit rowLimit, ResultHandler resultHandler) throws SQLException {
+  public List query(MappedStatement ms, Object parameterObject, RowBounds rowBounds, ResultHandler resultHandler) throws SQLException {
     if (ms != null) {
       Cache cache = ms.getCache();
       if (cache != null) {
@@ -46,23 +46,23 @@
         cache.getReadWriteLock().readLock().lock();
         try {
           if (ms.isUseCache()) {
-            CacheKey key = createCacheKey(ms, parameterObject, rowLimit);
+            CacheKey key = createCacheKey(ms, parameterObject, rowBounds);
             if (cache.hasKey(key)) {
               return (List) cache.getObject(key);
             } else {
-              List list = delegate.query(ms, parameterObject, rowLimit, resultHandler);
+              List list = delegate.query(ms, parameterObject, rowBounds, resultHandler);
               tcm.putObject(cache, key, list);
               return list;
             }
           } else {
-            return delegate.query(ms, parameterObject, rowLimit, resultHandler);
+            return delegate.query(ms, parameterObject, rowBounds, resultHandler);
           }
         } finally {
           cache.getReadWriteLock().readLock().unlock();
         }
       }
     }
-    return delegate.query(ms, parameterObject, rowLimit, resultHandler);
+    return delegate.query(ms, parameterObject, rowBounds, resultHandler);
   }
 
   public List flushStatements() throws SQLException {
@@ -82,8 +82,8 @@
     }
   }
 
-  public CacheKey createCacheKey(MappedStatement ms, Object parameterObject, RowLimit rowLimit) {
-    return delegate.createCacheKey(ms, parameterObject, rowLimit);
+  public CacheKey createCacheKey(MappedStatement ms, Object parameterObject, RowBounds rowBounds) {
+    return delegate.createCacheKey(ms, parameterObject, rowBounds);
   }
 
   public boolean isCached(MappedStatement ms, CacheKey key) {

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/Executor.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/Executor.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/Executor.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/Executor.java Sat Oct 10 05:18:38 2009
@@ -2,7 +2,7 @@
 
 import org.apache.ibatis.cache.CacheKey;
 import org.apache.ibatis.executor.result.ResultHandler;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.MappedStatement;
 import org.apache.ibatis.reflection.MetaObject;
 import org.apache.ibatis.transaction.Transaction;
@@ -16,7 +16,7 @@
 
   int update(MappedStatement ms, Object parameter) throws SQLException;
 
-  List query(MappedStatement ms, Object parameter, RowLimit rowLimit, ResultHandler resultHandler) throws SQLException;
+  List query(MappedStatement ms, Object parameter, RowBounds rowBounds, ResultHandler resultHandler) throws SQLException;
 
   List<BatchResult> flushStatements() throws SQLException;
 
@@ -24,7 +24,7 @@
 
   void rollback(boolean required) throws SQLException;
 
-  CacheKey createCacheKey(MappedStatement ms, Object parameterObject, RowLimit rowLimit);
+  CacheKey createCacheKey(MappedStatement ms, Object parameterObject, RowBounds rowBounds);
 
   boolean isCached(MappedStatement ms, CacheKey key);
 

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/ReuseExecutor.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/ReuseExecutor.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/ReuseExecutor.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/ReuseExecutor.java Sat Oct 10 05:18:38 2009
@@ -2,7 +2,7 @@
 
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.executor.statement.StatementHandler;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.*;
 import org.apache.ibatis.transaction.Transaction;
 
@@ -20,14 +20,14 @@
   public int doUpdate(MappedStatement ms, Object parameter)
       throws SQLException {
     Configuration configuration = ms.getConfiguration();
-    StatementHandler handler = configuration.newStatementHandler(this, ms, parameter, RowLimit.DEFAULT, null);
+    StatementHandler handler = configuration.newStatementHandler(this, ms, parameter, RowBounds.DEFAULT, null);
     Statement stmt = prepareStatement(handler);
     return handler.update(stmt);
   }
 
-  public List doQuery(MappedStatement ms, Object parameter, RowLimit rowLimit, ResultHandler resultHandler) throws SQLException {
+  public List doQuery(MappedStatement ms, Object parameter, RowBounds rowBounds, ResultHandler resultHandler) throws SQLException {
     Configuration configuration = ms.getConfiguration();
-    StatementHandler handler = configuration.newStatementHandler(this, ms, parameter, rowLimit, resultHandler);
+    StatementHandler handler = configuration.newStatementHandler(this, ms, parameter, rowBounds, resultHandler);
     Statement stmt = prepareStatement(handler);
     return handler.query(stmt, resultHandler);
   }

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/SimpleExecutor.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/SimpleExecutor.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/SimpleExecutor.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/SimpleExecutor.java Sat Oct 10 05:18:38 2009
@@ -2,7 +2,7 @@
 
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.executor.statement.StatementHandler;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.*;
 import org.apache.ibatis.transaction.Transaction;
 
@@ -20,7 +20,7 @@
     Statement stmt = null;
     try {
       Configuration configuration = ms.getConfiguration();
-      StatementHandler handler = configuration.newStatementHandler(this, ms, parameter, RowLimit.DEFAULT, null);
+      StatementHandler handler = configuration.newStatementHandler(this, ms, parameter, RowBounds.DEFAULT, null);
       stmt = prepareStatement(handler);
       return handler.update(stmt);
     } finally {
@@ -28,11 +28,11 @@
     }
   }
 
-  public List doQuery(MappedStatement ms, Object parameter, RowLimit rowLimit, ResultHandler resultHandler) throws SQLException {
+  public List doQuery(MappedStatement ms, Object parameter, RowBounds rowBounds, ResultHandler resultHandler) throws SQLException {
     Statement stmt = null;
     try {
       Configuration configuration = ms.getConfiguration();
-      StatementHandler handler = configuration.newStatementHandler(this, ms, parameter, rowLimit, resultHandler);
+      StatementHandler handler = configuration.newStatementHandler(this, ms, parameter, rowBounds, resultHandler);
       stmt = prepareStatement(handler);
       return handler.query(stmt, resultHandler);
     } finally {

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/keygen/SelectKeyGenerator.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/keygen/SelectKeyGenerator.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/keygen/SelectKeyGenerator.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/keygen/SelectKeyGenerator.java Sat Oct 10 05:18:38 2009
@@ -1,7 +1,7 @@
 package org.apache.ibatis.executor.keygen;
 
 import org.apache.ibatis.executor.*;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.*;
 import org.apache.ibatis.reflection.MetaObject;
 
@@ -44,7 +44,7 @@
               // Do not close keyExecutor.
               // The transaction will be closed by parent executor.
               Executor keyExecutor = configuration.newExecutor(executor.getTransaction(), ExecutorType.SIMPLE);
-              List values = keyExecutor.query(keyStatement, parameter, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+              List values = keyExecutor.query(keyStatement, parameter, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
               if (values.size() > 1) {
                 throw new ExecutorException("Select statement for SelectKeyGenerator returned more than one value.");
               }

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/loader/ResultLoader.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/loader/ResultLoader.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/loader/ResultLoader.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/loader/ResultLoader.java Sat Oct 10 05:18:38 2009
@@ -1,7 +1,7 @@
 package org.apache.ibatis.executor.loader;
 
 import org.apache.ibatis.executor.*;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.MappedStatement;
 import org.apache.ibatis.mapping.Configuration;
 import org.apache.ibatis.mapping.Environment;
@@ -64,7 +64,7 @@
       localExecutor = newExecutor();
     }
     try {
-      return localExecutor.query(mappedStatement, parameterObject, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      return localExecutor.query(mappedStatement, parameterObject, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
     } finally {
       if (executor.isClosed()) {
         localExecutor.close();

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/DefaultResultSetHandler.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/DefaultResultSetHandler.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/DefaultResultSetHandler.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/DefaultResultSetHandler.java Sat Oct 10 05:18:38 2009
@@ -25,7 +25,7 @@
   private final Executor executor;
   private final Configuration configuration;
   private final MappedStatement mappedStatement;
-  private final RowLimit rowLimit;
+  private final RowBounds rowBounds;
   private final ParameterHandler parameterHandler;
   private final ResultHandler resultHandler;
   private final BoundSql boundSql;
@@ -35,11 +35,11 @@
   private final Map<CacheKey,Set<CacheKey>> localRowValueCaches;
   private final Map<CacheKey,Object> globalRowValueCache;
 
-  public DefaultResultSetHandler(Executor executor, MappedStatement mappedStatement, ParameterHandler parameterHandler, ResultHandler resultHandler, BoundSql boundSql, RowLimit rowLimit) {
+  public DefaultResultSetHandler(Executor executor, MappedStatement mappedStatement, ParameterHandler parameterHandler, ResultHandler resultHandler, BoundSql boundSql, RowBounds rowBounds) {
     this.executor = executor;
     this.configuration = mappedStatement.getConfiguration();
     this.mappedStatement = mappedStatement;
-    this.rowLimit = rowLimit;
+    this.rowBounds = rowBounds;
     this.parameterHandler = parameterHandler;
     this.boundSql = boundSql;
     this.typeHandlerRegistry = configuration.getTypeHandlerRegistry();
@@ -75,7 +75,7 @@
     if (resultMapId != null) {
       final ResultMap resultMap = configuration.getResultMap(resultMapId);
       final DefaultResultHandler resultHandler = new DefaultResultHandler();
-      handleRowValues(rs, resultMap, resultHandler, new RowLimit());
+      handleRowValues(rs, resultMap, resultHandler, new RowBounds());
       metaParam.setValue(parameterMapping.getProperty(), resultHandler.getResultList());
     } else {
       throw new ExecutorException("Parameter requires ResultMap for output types of java.sql.ResultSet");
@@ -105,10 +105,10 @@
   private void handleResultSet(ResultSet rs, ResultMap resultMap, List multipleResults) throws SQLException {
     if (resultHandler == null) {
       DefaultResultHandler defaultResultHandler = new DefaultResultHandler();
-      handleRowValues(rs, resultMap, defaultResultHandler, rowLimit);
+      handleRowValues(rs, resultMap, defaultResultHandler, rowBounds);
       multipleResults.add(defaultResultHandler.getResultList());
     } else {
-      handleRowValues(rs, resultMap, resultHandler, rowLimit);
+      handleRowValues(rs, resultMap, resultHandler, rowBounds);
     }
   }
 
@@ -124,10 +124,10 @@
   // HANDLE ROWS
   //
 
-  private void handleRowValues(ResultSet rs, ResultMap resultMap, ResultHandler resultHandler, RowLimit rowLimit) throws SQLException {
+  private void handleRowValues(ResultSet rs, ResultMap resultMap, ResultHandler resultHandler, RowBounds rowBounds) throws SQLException {
     final DefaultResultContext resultContext = new DefaultResultContext();
-    skipRows(rs, rowLimit);
-    while (shouldProcessMoreRows(rs, resultContext.getResultCount(), rowLimit)) {
+    skipRows(rs, rowBounds);
+    while (shouldProcessMoreRows(rs, resultContext.getResultCount(), rowBounds)) {
       final ResultMap discriminatedResultMap = resolveDiscriminatedResultMap(rs, resultMap);
       final CacheKey rowKey = createRowKey(discriminatedResultMap, rs);
       final boolean knownValue = globalRowValueCache.containsKey(rowKey);
@@ -139,15 +139,15 @@
     }
   }
 
-  private boolean shouldProcessMoreRows(ResultSet rs, int count, RowLimit rowLimit) throws SQLException {
-    return rs.next() && count < rowLimit.getLimit();
+  private boolean shouldProcessMoreRows(ResultSet rs, int count, RowBounds rowBounds) throws SQLException {
+    return rs.next() && count < rowBounds.getLimit();
   }
 
-  private void skipRows(ResultSet rs, RowLimit rowLimit) throws SQLException {
+  private void skipRows(ResultSet rs, RowBounds rowBounds) throws SQLException {
     if (rs.getType() != ResultSet.TYPE_FORWARD_ONLY) {
-      rs.absolute(rowLimit.getOffset());
+      rs.absolute(rowBounds.getOffset());
     } else {
-      for (int i = 0; i < rowLimit.getOffset(); i++) rs.next();
+      for (int i = 0; i < rowBounds.getOffset(); i++) rs.next();
     }
   }
 
@@ -342,7 +342,7 @@
     final Object nestedQueryParameterObject = prepareParameterForNestedQuery(rs, propertyMapping, nestedQueryParameterType);
     Object value = null;
     if (nestedQueryParameterObject != null) {
-      final CacheKey key = executor.createCacheKey(nestedQuery, nestedQueryParameterObject, RowLimit.DEFAULT);
+      final CacheKey key = executor.createCacheKey(nestedQuery, nestedQueryParameterObject, RowBounds.DEFAULT);
       if (executor.isCached(nestedQuery, key)) {
         executor.deferLoad(nestedQuery, metaResultObject, property, key);
       } else {

Copied: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowBounds.java (from r822575, ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowLimit.java)
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowBounds.java?p2=ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowBounds.java&p1=ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowLimit.java&r1=822575&r2=823792&rev=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowLimit.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/resultset/RowBounds.java Sat Oct 10 05:18:38 2009
@@ -1,20 +1,20 @@
 package org.apache.ibatis.executor.resultset;
 
-public class RowLimit {
+public class RowBounds {
 
   public final static int NO_ROW_OFFSET = 0;
   public final static int NO_ROW_LIMIT = Integer.MAX_VALUE;
-  public final static RowLimit DEFAULT = new RowLimit();
+  public final static RowBounds DEFAULT = new RowBounds();
 
   private int offset;
   private int limit;
 
-  public RowLimit() {
+  public RowBounds() {
     this.offset = NO_ROW_OFFSET;
     this.limit = NO_ROW_LIMIT;
   }
 
-  public RowLimit(int offset, int limit) {
+  public RowBounds(int offset, int limit) {
     this.offset = offset;
     this.limit = limit;
   }

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/BaseStatementHandler.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/BaseStatementHandler.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/BaseStatementHandler.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/BaseStatementHandler.java Sat Oct 10 05:18:38 2009
@@ -5,7 +5,7 @@
 import org.apache.ibatis.executor.parameter.ParameterHandler;
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.executor.resultset.ResultSetHandler;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.*;
 import org.apache.ibatis.reflection.factory.ObjectFactory;
 import org.apache.ibatis.reflection.MetaObject;
@@ -23,15 +23,15 @@
 
   protected final Executor executor;
   protected final MappedStatement mappedStatement;
-  protected final RowLimit rowLimit;
+  protected final RowBounds rowBounds;
 
   protected final BoundSql boundSql;
 
-  protected BaseStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameterObject, RowLimit rowLimit, ResultHandler resultHandler) {
+  protected BaseStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameterObject, RowBounds rowBounds, ResultHandler resultHandler) {
     this.configuration = mappedStatement.getConfiguration();
     this.executor = executor;
     this.mappedStatement = mappedStatement;
-    this.rowLimit = rowLimit;
+    this.rowBounds = rowBounds;
 
     this.typeHandlerRegistry = configuration.getTypeHandlerRegistry();
     this.objectFactory = configuration.getObjectFactory();
@@ -39,7 +39,7 @@
     this.boundSql = mappedStatement.getBoundSql(parameterObject);
 
     this.parameterHandler = configuration.newParameterHandler(mappedStatement, parameterObject, boundSql);
-    this.resultSetHandler = configuration.newResultSetHandler(executor, mappedStatement, rowLimit, parameterHandler, resultHandler, boundSql);
+    this.resultSetHandler = configuration.newResultSetHandler(executor, mappedStatement, rowBounds, parameterHandler, resultHandler, boundSql);
   }
 
   public BoundSql getBoundSql() {

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/CallableStatementHandler.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/CallableStatementHandler.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/CallableStatementHandler.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/CallableStatementHandler.java Sat Oct 10 05:18:38 2009
@@ -1,7 +1,7 @@
 package org.apache.ibatis.executor.statement;
 
 import org.apache.ibatis.executor.*;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.executor.keygen.KeyGenerator;
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.mapping.*;
@@ -12,8 +12,8 @@
 
 public class CallableStatementHandler extends BaseStatementHandler {
 
-  public CallableStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameter, RowLimit rowLimit, ResultHandler resultHandler) {
-    super(executor, mappedStatement, parameter, rowLimit, resultHandler);
+  public CallableStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameter, RowBounds rowBounds, ResultHandler resultHandler) {
+    super(executor, mappedStatement, parameter, rowBounds, resultHandler);
   }
 
   public int update(Statement statement)

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/PreparedStatementHandler.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/PreparedStatementHandler.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/PreparedStatementHandler.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/PreparedStatementHandler.java Sat Oct 10 05:18:38 2009
@@ -1,7 +1,7 @@
 package org.apache.ibatis.executor.statement;
 
 import org.apache.ibatis.executor.Executor;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.executor.keygen.*;
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.mapping.MappedStatement;
@@ -11,8 +11,8 @@
 
 public class PreparedStatementHandler extends BaseStatementHandler {
 
-  public PreparedStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameter, RowLimit rowLimit, ResultHandler resultHandler) {
-    super(executor, mappedStatement, parameter, rowLimit, resultHandler);
+  public PreparedStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameter, RowBounds rowBounds, ResultHandler resultHandler) {
+    super(executor, mappedStatement, parameter, rowBounds, resultHandler);
   }
 
   public int update(Statement statement)

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/RoutingStatementHandler.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/RoutingStatementHandler.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/RoutingStatementHandler.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/RoutingStatementHandler.java Sat Oct 10 05:18:38 2009
@@ -1,7 +1,7 @@
 package org.apache.ibatis.executor.statement;
 
 import org.apache.ibatis.executor.*;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.executor.parameter.ParameterHandler;
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.mapping.*;
@@ -13,17 +13,17 @@
 
   private final StatementHandler delegate;
 
-  public RoutingStatementHandler(Executor executor, MappedStatement ms, Object parameter, RowLimit rowLimit, ResultHandler resultHandler) {
+  public RoutingStatementHandler(Executor executor, MappedStatement ms, Object parameter, RowBounds rowBounds, ResultHandler resultHandler) {
 
     switch (ms.getStatementType()) {
       case STATEMENT:
-        delegate = new SimpleStatementHandler(executor, ms, parameter, rowLimit, resultHandler);
+        delegate = new SimpleStatementHandler(executor, ms, parameter, rowBounds, resultHandler);
         break;
       case PREPARED:
-        delegate = new PreparedStatementHandler(executor, ms, parameter, rowLimit, resultHandler);
+        delegate = new PreparedStatementHandler(executor, ms, parameter, rowBounds, resultHandler);
         break;
       case CALLABLE:
-        delegate = new CallableStatementHandler(executor, ms, parameter, rowLimit, resultHandler);
+        delegate = new CallableStatementHandler(executor, ms, parameter, rowBounds, resultHandler);
         break;
       default:
         throw new ExecutorException("Unknown statement type: " + ms.getStatementType());

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/SimpleStatementHandler.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/SimpleStatementHandler.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/SimpleStatementHandler.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/executor/statement/SimpleStatementHandler.java Sat Oct 10 05:18:38 2009
@@ -1,7 +1,7 @@
 package org.apache.ibatis.executor.statement;
 
 import org.apache.ibatis.executor.Executor;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.executor.keygen.*;
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.mapping.MappedStatement;
@@ -11,8 +11,8 @@
 
 public class SimpleStatementHandler extends BaseStatementHandler {
 
-  public SimpleStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameter, RowLimit rowLimit, ResultHandler resultHandler) {
-    super(executor, mappedStatement, parameter, rowLimit, resultHandler);
+  public SimpleStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameter, RowBounds rowBounds, ResultHandler resultHandler) {
+    super(executor, mappedStatement, parameter, rowBounds, resultHandler);
   }
 
   public int update(Statement statement)

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/mapping/Configuration.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/mapping/Configuration.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/mapping/Configuration.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/mapping/Configuration.java Sat Oct 10 05:18:38 2009
@@ -172,14 +172,14 @@
     return parameterHandler;
   }
 
-  public ResultSetHandler newResultSetHandler(Executor executor, MappedStatement mappedStatement, RowLimit rowLimit, ParameterHandler parameterHandler, ResultHandler resultHandler, BoundSql boundSql) {
-    ResultSetHandler resultSetHandler = new DefaultResultSetHandler(executor, mappedStatement, parameterHandler, resultHandler, boundSql, rowLimit);
+  public ResultSetHandler newResultSetHandler(Executor executor, MappedStatement mappedStatement, RowBounds rowBounds, ParameterHandler parameterHandler, ResultHandler resultHandler, BoundSql boundSql) {
+    ResultSetHandler resultSetHandler = new DefaultResultSetHandler(executor, mappedStatement, parameterHandler, resultHandler, boundSql, rowBounds);
     resultSetHandler = (ResultSetHandler) interceptorChain.pluginAll(resultSetHandler);
     return resultSetHandler;
   }
 
-  public StatementHandler newStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameterObject, RowLimit rowLimit, ResultHandler resultHandler) {
-    StatementHandler statementHandler = new RoutingStatementHandler(executor, mappedStatement, parameterObject, rowLimit, resultHandler);
+  public StatementHandler newStatementHandler(Executor executor, MappedStatement mappedStatement, Object parameterObject, RowBounds rowBounds, ResultHandler resultHandler) {
+    StatementHandler statementHandler = new RoutingStatementHandler(executor, mappedStatement, parameterObject, rowBounds, resultHandler);
     statementHandler = (StatementHandler) interceptorChain.pluginAll(statementHandler);
     return statementHandler;
   }

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/SqlSession.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/SqlSession.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/SqlSession.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/SqlSession.java Sat Oct 10 05:18:38 2009
@@ -1,7 +1,7 @@
 package org.apache.ibatis.session;
 
 import org.apache.ibatis.executor.result.ResultHandler;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.mapping.Configuration;
 
 import java.util.List;
@@ -17,11 +17,11 @@
 
   List selectList(String statement, Object parameter);
 
-  List selectList(String statement, Object parameter, RowLimit rowLimit);
+  List selectList(String statement, Object parameter, RowBounds rowBounds);
 
   void select(String statement, Object parameter, ResultHandler handler);
 
-  void select(String statement, Object parameter, RowLimit rowLimit, ResultHandler handler);
+  void select(String statement, Object parameter, RowBounds rowBounds, ResultHandler handler);
 
   int insert(String statement);
 

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/defaults/DefaultSqlSession.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/defaults/DefaultSqlSession.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/defaults/DefaultSqlSession.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/main/java/org/apache/ibatis/session/defaults/DefaultSqlSession.java Sat Oct 10 05:18:38 2009
@@ -3,7 +3,7 @@
 import org.apache.ibatis.exceptions.ExceptionFactory;
 import org.apache.ibatis.exceptions.TooManyResultsException;
 import org.apache.ibatis.executor.Executor;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.executor.result.ResultHandler;
 import org.apache.ibatis.mapping.*;
 import org.apache.ibatis.session.*;
@@ -48,26 +48,26 @@
   }
 
   public List selectList(String statement, Object parameter) {
-    return selectList(statement, parameter, RowLimit.DEFAULT);
+    return selectList(statement, parameter, RowBounds.DEFAULT);
   }
 
-  public List selectList(String statement, Object parameter, RowLimit rowLimit) {
+  public List selectList(String statement, Object parameter, RowBounds rowBounds) {
     try {
       MappedStatement ms = configuration.getMappedStatement(statement);
-      return executor.query(ms, wrapCollection(parameter), rowLimit, Executor.NO_RESULT_HANDLER);
+      return executor.query(ms, wrapCollection(parameter), rowBounds, Executor.NO_RESULT_HANDLER);
     } catch (Exception e) {
       throw ExceptionFactory.wrapException("Error querying database.  Cause: " + e, e);
     }
   }
 
   public void select(String statement, Object parameter, ResultHandler handler) {
-    select(statement, parameter, RowLimit.DEFAULT, handler);
+    select(statement, parameter, RowBounds.DEFAULT, handler);
   }
 
-  public void select(String statement, Object parameter, RowLimit rowLimit, ResultHandler handler) {
+  public void select(String statement, Object parameter, RowBounds rowBounds, ResultHandler handler) {
     try {
       MappedStatement ms = configuration.getMappedStatement(statement);
-      executor.query(ms, wrapCollection(parameter), rowLimit, handler);
+      executor.query(ms, wrapCollection(parameter), rowBounds, handler);
     } catch (Exception e) {
       throw ExceptionFactory.wrapException("Error querying database.  Cause: " + e, e);
     }

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/domain/blog/mappers/BlogMapper.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/domain/blog/mappers/BlogMapper.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/domain/blog/mappers/BlogMapper.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/domain/blog/mappers/BlogMapper.java Sat Oct 10 05:18:38 2009
@@ -1,6 +1,6 @@
 package domain.blog.mappers;
 
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 
 import java.util.*;
 
@@ -8,8 +8,8 @@
 
   List<Map> selectAllPosts();
 
-  List<Map> selectAllPosts(RowLimit rowLimit);
+  List<Map> selectAllPosts(RowBounds rowBounds);
 
-  List<Map> selectAllPosts(RowLimit rowLimit, Object param);
+  List<Map> selectAllPosts(RowBounds rowBounds, Object param);
 
 }

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BindingTest.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BindingTest.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BindingTest.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BindingTest.java Sat Oct 10 05:18:38 2009
@@ -2,7 +2,7 @@
 
 import domain.blog.*;
 import org.apache.ibatis.session.*;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import static org.junit.Assert.*;
 import org.junit.*;
 
@@ -70,7 +70,7 @@
     SqlSession session = sqlSessionFactory.openSession();
     try {
       BoundAuthorMapper mapper = session.getMapper(BoundAuthorMapper.class);
-      List<Post> posts = mapper.findThreeSpecificPosts(1,new RowLimit(1,1),3,5);
+      List<Post> posts = mapper.findThreeSpecificPosts(1,new RowBounds(1,1),3,5);
       assertEquals(1,posts.size());
       assertEquals(3,posts.get(0).getId());
       session.rollback();

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BoundAuthorMapper.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BoundAuthorMapper.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BoundAuthorMapper.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/binding/BoundAuthorMapper.java Sat Oct 10 05:18:38 2009
@@ -2,7 +2,7 @@
 
 import domain.blog.*;
 import org.apache.ibatis.annotations.*;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 
 import java.util.List;
 
@@ -65,7 +65,7 @@
   //======================================================
 
   List<Post> findThreeSpecificPosts(@Param("one") int one,
-                                    RowLimit rowLimit,
+                                    RowBounds rowBounds,
                                     @Param("two") int two,
                                     int three);
 }

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/executor/BaseExecutorTest.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/executor/BaseExecutorTest.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/executor/BaseExecutorTest.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/executor/BaseExecutorTest.java Sat Oct 10 05:18:38 2009
@@ -2,14 +2,13 @@
 
 import domain.blog.*;
 import org.apache.ibatis.BaseDataTest;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.logging.jdbc.ConnectionLogger;
 import org.apache.ibatis.mapping.*;
 import org.apache.ibatis.transaction.Transaction;
 import org.apache.ibatis.transaction.jdbc.JdbcTransaction;
 import static org.junit.Assert.*;
 import org.junit.Test;
-import org.junit.Ignore;
 
 import javax.sql.DataSource;
 import java.sql.Connection;
@@ -43,7 +42,7 @@
       }
       assertEquals(123456, author.getId());
       if (author.getId() != BatchExecutor.BATCH_UPDATE_RETURN_VALUE) {
-        List<Author> authors = executor.query(selectStatement, author.getId(), RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+        List<Author> authors = executor.query(selectStatement, author.getId(), RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
         executor.rollback(true);
         assertEquals(1, authors.size());
         assertEquals(author.toString(), authors.get(0).toString());
@@ -65,7 +64,7 @@
       MappedStatement insertStatement = ExecutorTestHelper.prepareInsertAuthorMappedStatement(config);
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectOneAuthorMappedStatement(config);
       int rows = executor.update(insertStatement, author);
-      List<Author> authors = executor.query(selectStatement, 99, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Author> authors = executor.query(selectStatement, 99, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       executor.rollback(true);
       assertEquals(1, authors.size());
@@ -83,7 +82,7 @@
     try {
       Executor executor = createExecutor(new JdbcTransaction(connection, false));
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectAllAuthorsAutoMappedStatement(config);
-      List<Author> authors = executor.query(selectStatement, null, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Author> authors = executor.query(selectStatement, null, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       assertEquals(2, authors.size());
       Author author = authors.get(0);
       // id,username, password, email, bio, favourite_section
@@ -115,7 +114,7 @@
       }
       assertTrue(-1 != author.getId());
       if (author.getId() != BatchExecutor.BATCH_UPDATE_RETURN_VALUE) {
-        List<Author> authors = executor.query(selectStatement, author.getId(), RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+        List<Author> authors = executor.query(selectStatement, author.getId(), RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
         executor.rollback(true);
         assertEquals(1, authors.size());
         assertEquals(author.toString(), authors.get(0).toString());
@@ -137,7 +136,7 @@
       MappedStatement insertStatement = ExecutorTestHelper.prepareInsertAuthorProc(config);
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectOneAuthorMappedStatement(config);
       int rows = executor.update(insertStatement, author);
-      List<Author> authors = executor.query(selectStatement, 97, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Author> authors = executor.query(selectStatement, 97, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       executor.rollback(true);
       assertEquals(1, authors.size());
@@ -158,7 +157,7 @@
       MappedStatement insertStatement = ExecutorTestHelper.createInsertAuthorWithIDof99MappedStatement(config);
       MappedStatement selectStatement = ExecutorTestHelper.createSelectAuthorWithIDof99MappedStatement(config);
       int rows = executor.update(insertStatement, null);
-      List<Author> authors = executor.query(selectStatement, 99, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Author> authors = executor.query(selectStatement, 99, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       executor.rollback(true);
       assertEquals(1, authors.size());
@@ -180,7 +179,7 @@
       MappedStatement updateStatement = ExecutorTestHelper.prepareUpdateAuthorMappedStatement(config);
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectOneAuthorMappedStatement(config);
       int rows = executor.update(updateStatement, author);
-      List<Author> authors = executor.query(selectStatement, 101, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Author> authors = executor.query(selectStatement, 101, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       executor.rollback(true);
       assertEquals(1, authors.size());
@@ -202,7 +201,7 @@
       MappedStatement deleteStatement = ExecutorTestHelper.prepareDeleteAuthorMappedStatement(config);
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectOneAuthorMappedStatement(config);
       int rows = executor.update(deleteStatement, author);
-      List<Author> authors = executor.query(selectStatement, 101, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Author> authors = executor.query(selectStatement, 101, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       executor.rollback(true);
       assertEquals(0, authors.size());
@@ -220,7 +219,7 @@
     try {
       Executor executor = createExecutor(new JdbcTransaction(connection, false));
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectDiscriminatedProduct(config);
-      List<Map> products = executor.query(selectStatement, null, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Map> products = executor.query(selectStatement, null, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       connection.rollback();
       assertEquals(16, products.size());
       for (Map m : products) {
@@ -243,7 +242,7 @@
     try {
       Executor executor = createExecutor(new JdbcTransaction(connection, false));
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectDiscriminatedProduct(config);
-      List<Map> products = executor.query(selectStatement, null, new RowLimit(4, 10), Executor.NO_RESULT_HANDLER);
+      List<Map> products = executor.query(selectStatement, null, new RowBounds(4, 10), Executor.NO_RESULT_HANDLER);
       connection.rollback();
       assertEquals(10, products.size());
       for (Map m : products) {
@@ -273,7 +272,7 @@
           put("id1", 101);
           put("id2", 102);
         }
-      }, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      }, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       connection.rollback();
       assertEquals(2, authorSets.size());
       for (List authors : authorSets) {
@@ -297,7 +296,7 @@
       Executor executor = createExecutor(new JdbcTransaction(connection, false));
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectAuthorViaOutParams(config);
       Author author = new Author(102, null, null, null, null, null);
-      executor.query(selectStatement, author, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      executor.query(selectStatement, author, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       connection.rollback();
 
       assertEquals("sally", author.getUsername());
@@ -321,7 +320,7 @@
       MappedStatement selectPosts = ExecutorTestHelper.prepareSelectPostsForBlogMappedStatement(config);
       config.addMappedStatement(selectBlog);
       config.addMappedStatement(selectPosts);
-      List<Post> posts = executor.query(selectPosts, 1, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Post> posts = executor.query(selectPosts, 1, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       assertEquals(2, posts.size());
       assertNotNull(posts.get(1).getBlog());
@@ -343,7 +342,7 @@
       MappedStatement selectPost = ExecutorTestHelper.prepareSelectPostMappedStatement(config);
       config.addMappedStatement(selectBlog);
       config.addMappedStatement(selectPost);
-      List<Post> posts = executor.query(selectPost, 5, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Post> posts = executor.query(selectPost, 5, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       executor.rollback(true);
       assertEquals(1, posts.size());
@@ -365,7 +364,7 @@
       MappedStatement selectPost = ExecutorTestHelper.prepareSelectPostWithBlogByAuthorMappedStatement(config);
       config.addMappedStatement(selectBlog);
       config.addMappedStatement(selectPost);
-      List<Post> posts = executor.query(selectPost, 2, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Post> posts = executor.query(selectPost, 2, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       assertEquals(1, posts.size());
       Post post = posts.get(0);
@@ -390,7 +389,7 @@
       config.addMappedStatement(selectBlog);
       config.addMappedStatement(selectPosts);
       config.setLazyLoadingEnabled(true);
-      List<Blog> blogs = executor.query(selectBlog, 1, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Blog> blogs = executor.query(selectBlog, 1, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       assertEquals(1, blogs.size());
       assertEquals(2, blogs.get(0).getPosts().size());
@@ -410,7 +409,7 @@
     try {
       Executor executor = createExecutor(new JdbcTransaction(connection, false));
       MappedStatement selectStatement = ExecutorTestHelper.prepareSelectOneAuthorMappedStatementWithConstructorResults(config);
-      List<Author> authors = executor.query(selectStatement, 102, RowLimit.DEFAULT, Executor.NO_RESULT_HANDLER);
+      List<Author> authors = executor.query(selectStatement, 102, RowBounds.DEFAULT, Executor.NO_RESULT_HANDLER);
       executor.flushStatements();
       executor.rollback(true);
       assertEquals(1, authors.size());

Modified: ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/session/SqlSessionTest.java
URL: http://svn.apache.org/viewvc/ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/session/SqlSessionTest.java?rev=823792&r1=823791&r2=823792&view=diff
==============================================================================
--- ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/session/SqlSessionTest.java (original)
+++ ibatis/java/ibatis-3/trunk/ibatis-3-core/src/test/java/org/apache/ibatis/session/SqlSessionTest.java Sat Oct 10 05:18:38 2009
@@ -3,7 +3,7 @@
 import domain.blog.*;
 import domain.blog.mappers.*;
 import org.apache.ibatis.BaseDataTest;
-import org.apache.ibatis.executor.resultset.RowLimit;
+import org.apache.ibatis.executor.resultset.RowBounds;
 import org.apache.ibatis.io.Resources;
 import org.apache.ibatis.mapping.Configuration;
 import static org.junit.Assert.*;
@@ -452,7 +452,7 @@
     SqlSession session = sqlMapper.openSession();
     try {
       BlogMapper mapper = session.getMapper(BlogMapper.class);
-      List<Map> posts = mapper.selectAllPosts(new RowLimit(0, 2), null);
+      List<Map> posts = mapper.selectAllPosts(new RowBounds(0, 2), null);
       assertEquals(2, posts.size());
       assertEquals(1, posts.get(0).get("ID"));
       assertEquals(2, posts.get(1).get("ID"));
@@ -466,7 +466,7 @@
     SqlSession session = sqlMapper.openSession();
     try {
       BlogMapper mapper = session.getMapper(BlogMapper.class);
-      List<Map> posts = mapper.selectAllPosts(new RowLimit(2, 3));
+      List<Map> posts = mapper.selectAllPosts(new RowBounds(2, 3));
       assertEquals(3, posts.size());
       assertEquals(3, posts.get(0).get("ID"));
       assertEquals(4, posts.get(1).get("ID"));