/** @inheritdoc */
 @Override
 public void readEntity(Cursor cursor, UserActivity entity, int offset) {
   entity.setId(cursor.isNull(offset + 0) ? null : cursor.getLong(offset + 0));
   entity.setType(cursor.isNull(offset + 1) ? null : cursor.getString(offset + 1));
   entity.setSummary(cursor.isNull(offset + 2) ? null : cursor.getString(offset + 2));
   entity.setDescription(cursor.isNull(offset + 3) ? null : cursor.getString(offset + 3));
   entity.setClassified(cursor.isNull(offset + 4) ? null : cursor.getShort(offset + 4) != 0);
   entity.setLevelOfJoy(cursor.isNull(offset + 5) ? null : cursor.getInt(offset + 5));
   entity.setStartDate(cursor.isNull(offset + 6) ? null : cursor.getLong(offset + 6));
   entity.setEndDate(cursor.isNull(offset + 7) ? null : cursor.getLong(offset + 7));
 }
  public static UserActivity mapToDB(ActivityDTO activity) {
    UserActivity userActivity = new UserActivity();
    userActivity.setId(activity.getId());
    userActivity.setStartDate(activity.getStartDate());
    userActivity.setClassified(activity.isClassified());
    userActivity.setEndDate(activity.getEndDate());
    userActivity.setDescription(activity.getDescription());
    userActivity.setLevelOfJoy(activity.getLevelOfJoy());
    userActivity.setSummary(activity.getSummary());
    userActivity.setType(activity.getType());

    return userActivity;
  }