private float amount;
private boolean amountSet = false;
private String currency;
-
- public LedgerTransactionAccount(String accountName, float amount) {
- this(accountName, amount, null);
- }
- public LedgerTransactionAccount(String accountName, float amount, String currency) {
+ private String comment;
+ public LedgerTransactionAccount(String accountName, float amount, String currency,
+ String comment) {
this.setAccountName(accountName);
this.amount = amount;
this.amountSet = true;
this.currency = currency;
+ this.comment = comment;
}
-
public LedgerTransactionAccount(String accountName) {
this.accountName = accountName;
}
public LedgerTransactionAccount(LedgerTransactionAccount origin) {
// copy constructor
setAccountName(origin.getAccountName());
+ setComment(origin.getComment());
if (origin.isAmountSet())
setAmount(origin.getAmount());
currency = origin.getCurrency();
}
-
+ public String getComment() {
+ return comment;
+ }
+ public void setComment(String comment) {
+ this.comment = comment;
+ }
public String getAccountName() {
return accountName;
}