MailingAddress.java
Contact.java, Friend.java, BusinessAssociate.java
AdressBook.java, AddressBookTester.java
Then I have to have a MailingAddressTester
MailingAddressTester program to output? For example, run the program and enter the following values:
Enter the street address: 91 George Road
Enter the city: Raleigh
Enter the state: CA
Enter the zipcode: 12345
A BusinessAssociate class
IMPLEMENT THE FRIEND CLASS
Implement a class named Friend which extends the Contact class. The Friend class should have a field that represents the friend's birthday. For simplicity, the birthdate can be represented with a String. Provide one or more constructors and the appropriate mutator / accessor methods (getter and setter methods) for the friend's birthday. Override the toString method to convert a Friend object to a string of the following form:
full name, email, birthday
IMPLEMENT THE BUSINESSASSOCIATE CLASS
Implement a class named BusinessAssociate which inherits from the Contact class. The BusinessAssociate class should have a field that represents the company affiliation, a field to store the business associate's title (Mr., Mrs., Dr., etc.), and a field to store the associate's current position (Project Manager, Software Engineer, CEO, etc.). Provide one or more constructors and the appropriate mutator / accessor methods for the instance variables. The BusinessAssociate should override the getFullName()method to add the associate's title to the full name (for example, Dr. John Smith). Override the toString() method to convert a BusinessAssociate object to a string of the following form:
Complete the class AddressBook included in the labfiles10.zip file. The AddressBook class is used to keep track of multiple contacts. In the AddressBook class there should be a single instance variable to hold the list of contacts in the address book. You should implement the following methods in the AddressBook class:
Method
Description
public ArrayList getEmailList()
Returns a list containing a
String for the email address for each of the contacts in
the contact list.
public ArrayList getFriends()
Returns a list containing a String for each of the friends in the contact list. Each
friend should be converted to a String using the toString method of the Friend class.
public String toString()
Override the toString method to return a string representing all the contacts in the AddresBook. Each contact should be appended to the string using the toString method defined for that contact.
Write a simple tester program called AddressBookTester that does the following:
• Creates an address book
• Adds the following contacts:
o Friend: John Smith, *****@******.***, 01/14/80
o Friend: Joe Adams, *****@******.***, 07/10/82
o Business Associate: Mrs. Sue Johnson, *****@******.***, Acme Inc., Sales
• Displays all contacts in the address book (use the toString method of the AddressBook).
• Displays the list of all email addresses separated by commas. The list of comma separated emails should be preceded by the heading Email List.
• Displays a list of all the friends in the address book. The list of comma separated friends should be preceded by the heading Friends List.
• Program output should look like this: