|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--Customer
Class that describes a customer of a bank
Field Summary | |
(package private) BankAccount |
account
account for this customer |
Constructor Summary | |
Customer(String firstName,
String lastName,
double amount)
Constructor to create a new customer and create an account for this customer |
Method Summary | |
boolean |
equals(Object o)
Method to check if two customer objects are equal (have the same id) |
BankAccount |
getAccount()
Method to get the account |
int |
getId()
Method to get the id for this customer |
String |
getName()
Method to get the customer name |
static void |
main(String[] argv)
Method to test |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
BankAccount account
Constructor Detail |
public Customer(String firstName, String lastName, double amount)
firstName
- the first name for the customerlastName
- the last name for the customeramount
- the amount to deposit in the new accountMethod Detail |
public int getId()
public boolean equals(Object o)
equals
in class Object
public String getName()
public BankAccount getAccount()
public static void main(String[] argv)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |