public CachedObject getNewCachedObject(Session session, Object object) {

    Row row = new RowAVLDisk(table, (Object[]) object);

    add(row);

    if (session != null) {
      RowAction.addAction(session, RowAction.ACTION_INSERT, table, row);
    }

    return row;
  }
  public CachedObject getNewCachedObject(Session session, Object object) {

    Row row = new RowAVL(table, (Object[]) object);

    if (session != null) {
      RowAction.addAction(session, RowAction.ACTION_INSERT, table, row);
    }

    synchronized (this) {
      int id = rowIdSequence++;

      row.setPos(id);
      rowIdMap.put(id, row);
    }

    return row;
  }