Example #1
0
 /** @inheritdoc */
 @Override
 public void readEntity(Cursor cursor, Bank entity, int offset) {
   entity.setId(cursor.isNull(offset + 0) ? null : cursor.getLong(offset + 0));
   entity.setName(cursor.getString(offset + 1));
   entity.setUpdatedDate(
       cursor.isNull(offset + 2) ? null : new java.util.Date(cursor.getLong(offset + 2)));
 }
Example #2
0
  /** @inheritdoc */
  @Override
  protected void bindValues(SQLiteStatement stmt, Bank entity) {
    stmt.clearBindings();

    Long id = entity.getId();
    if (id != null) {
      stmt.bindLong(1, id);
    }
    stmt.bindString(2, entity.getName());

    java.util.Date updatedDate = entity.getUpdatedDate();
    if (updatedDate != null) {
      stmt.bindLong(3, updatedDate.getTime());
    }
  }
Example #3
0
 /** @inheritdoc */
 @Override
 public Long getKey(Bank entity) {
   if (entity != null) {
     return entity.getId();
   } else {
     return null;
   }
 }
Example #4
0
 @Override
 protected void attachEntity(Bank entity) {
   super.attachEntity(entity);
   entity.__setDaoSession(daoSession);
 }
Example #5
0
 /** @inheritdoc */
 @Override
 protected Long updateKeyAfterInsert(Bank entity, long rowId) {
   entity.setId(rowId);
   return rowId;
 }