|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Electronic telephone book task!
I have a task to do which invovles creating an electronic telephone book, ive jus started using java and havnt got a clue how to code each class, so if any1 could post the coding needed to make each class work i would be most grateful! cheers people!
Below is the task i was set - Develop a Java application to create and manage an electronic telephone book. The book will contain information about home and overseas friends. The abstract class Friend will have the following attributes: name; email; tel; And the following methods: Friend(); //a constructor that will set up all values to “Unknown” public void getData(String newName, String newEmail, String newTel)where data is saved in three parallel arrays names[], emails[], telNums[]; public string search(); (10) public void displayAll();//before sorting public void displaySorted(); A derived class HomeFriend will extend the base class by adding an attribute: int areaCode; and 3 methods: HomeFriend(); //constructor that sets the area code to 0 as default public void getAreaCode(int newAreaCode); //get value from user public String displayAll(); (5) public void displaySorted();//after sorting (5) OverseasFriend class will extend the base class by adding an attribute: int countryCode; and 3 methods: OverseasFriend();//constructor that will set default country code to 0 public void getCountryCode(int newCountryCode); public String displayAll(); (5) public void displaySorted();//after sorting (5) The application will also include a datastore to save data. Discuss any inheritance or use associations as part of your design using UML notations. |
|
#2
|
||||
|
||||
|
Perhaps if you post some of your code, we could help you learn off of that.
We're not going to do your projects for you. |
![]() |
| Viewing: Dev Articles Community Forums > Programming > Java Development > Electronic telephone book task! |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|