Hi all!
Can anyone help me to figure out what this exercise is asking me to do?
1. The homework is to modify the MyPersonMultipleInterfaces project above.
(You might want to create a new project by copying the
MyGetPersonMultipleInterfaces project.) You can name the new project in any
way you want but here I am going to call to call it as
MyGetPersonMultipleInterfaces2.
- Write an interface called MyOwnInterface, which has the following
method
- AddressInterface getAddress();
- The AddressInterface is a Java interface that has the following
methods.
- int getStreetNumber();
- void setStreetNumber(int streetNumber);
- String getStreetName();
- void setStreetName(String streetName);
- String getCountry();
- void setCountry(String country);
- Write AddressImpl class that implements AddressInterface
- Make the Person class to implement MyOwnInterface.
- Initialize a Person object with proper data and display it.
I couldn't understand what means the first part when it said to create a
method AddressInterface getAddress() in MyOwnInterface and after it said to
"Make the Person class to implement MyOwnInterface". What this method
getAddress will return? What data type?
Tks a lot!
--
[]s
Fabio C Donadon
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/javaprogrammingwithpassion?hl=en
-~----------~----~----~----~------~----~------~--~---