+ static public LedgerAmount fromDBO(AccountValue dbo) {
+ final LedgerAmount ledgerAmount = new LedgerAmount(dbo.getValue(), dbo.getCurrency());
+ ledgerAmount.dbId = dbo.getId();
+ return ledgerAmount;
+ }
+ public AccountValue toDBO(Account account) {
+ final AccountValueDAO dao = DB.get()
+ .getAccountValueDAO();
+ AccountValue obj = new AccountValue();
+ obj.setId(dbId);
+ obj.setAccountId(account.getId());
+
+ obj.setCurrency(currency);
+ obj.setValue(amount);