Ejemplo n.º 1
0
  /** Turn a cursor to a Building entity */
  private Building cursorToBuilding(Cursor cursor) {
    Building building = new Building();

    building.setId(cursor.getLong(0));
    building.setName(cursor.getString(1));
    building.setDescription(cursor.getString(2));
    building.setMap(cursor.getString(3));

    return building;
  }
Ejemplo n.º 2
0
 public Building insert(Building building) {
   return this.insert(building.getName(), building.getDescription(), building.getMap());
 }