예제 #1
0
  public int buildResult(ResultSet res, boolean ispagine, RowHandler rowHandler)
      throws SQLException {
    rowcount = 0;
    if (meta == null) this.cacheResultSetMetaData(res, ispagine);

    boolean go = true;
    if (ispagine) go = res.next() && rowcount < getMaxsize();
    else go = res.next();
    // 从结果集中获取当前游标后maxsize条记录
    while (go) {
      ResultMap.buildRecord(res, this, rowHandler, this.dbadapter);
      rowcount++;
      if (ispagine) go = res.next() && rowcount < getMaxsize();
      else go = res.next();
    }

    return rowcount;
  }