Skip to content

Conversation

@PParfenov
Copy link

Looking for feedback

private double accountBalance = 0.00d;
private List<User> accountUsers = new ArrayList<User>();
private AccountStatus accountStatus = AccountStatus.ACTIVE;
private List<Transaction> accountTransactionHistory = new ArrayList<Transaction>();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice declaration of the abstract type List and instantiation of concrete type ArrayList! 👍

}

public void setAccountID(int accountID) {
this.accountID = String.format( "%0" + AccountFactory.ACCOUNT_ID_LENGTH + "d", accountID);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 me gusta

this.getTransactionHistory().add(transaction);
}

public Transaction withdrawAndMakeTransaction(double amount) throws TransactionAmountIsZeroException, BalanceTooLowException {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice use of throws

package com.zipcode.macrolabs.atm.navigation;

public class BankAccountManager {

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

// TODO - Remove this class

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants