コード例 #1
0
 @Override
 public void updateAccount() {
   ObjectDao<ChequingAccount> checkingAccountDao = new ObjectDao<ChequingAccount>();
   checkingAccountDao.updateObject(this, this.getAccountId(), ChequingAccount.class);
   //        String setString = " balance = " + this.getBalance();
   //       // setString +=
   //        String whereString= " account.accountId = " + this.getAccountId();
   //        checkingAccountDao.updateUsingSQL("ChequingAccount account ", setString, whereString);
 }
コード例 #2
0
 public static List<ChequingAccount> getCheckingAccounts() {
   ObjectDao<ChequingAccount> dao = new ObjectDao<ChequingAccount>();
   return dao.getAllObjects(ChequingAccount.class, "ChequingAccount");
 }
コード例 #3
0
  public static ChequingAccount getCheckingAccountById(long id) {

    ObjectDao<ChequingAccount> dao = new ObjectDao<ChequingAccount>();
    return dao.getObjectById(id, ChequingAccount.class);
  }
コード例 #4
0
 @Override
 public void deleteAccount() {
   ObjectDao<ChequingAccount> checkingAccountDao = new ObjectDao<ChequingAccount>();
   checkingAccountDao.deleteObject(this, this.getAccountId(), ChequingAccount.class);
 }
コード例 #5
0
 @Override
 public void saveAccount() {
   ObjectDao<ChequingAccount> accountDao = new ObjectDao<ChequingAccount>();
   accountDao.addObject(this);
 }