0% found this document useful (0 votes)
40 views2 pages

A Damien

The document describes an experiment to create an AddressBookEntry class with attributes for a person's name, address, telephone number, and email address. The class must include accessor and mutator methods for each attribute, as well as constructors. A separate AddressBook class must also be created to contain 100 AddressBookEntry objects. The purpose of accessor and mutator methods is to set attribute values and retrieve attribute values when instantiating objects in a program.

Uploaded by

api-26570979
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
40 views2 pages

A Damien

The document describes an experiment to create an AddressBookEntry class with attributes for a person's name, address, telephone number, and email address. The class must include accessor and mutator methods for each attribute, as well as constructors. A separate AddressBook class must also be created to contain 100 AddressBookEntry objects. The purpose of accessor and mutator methods is to set attribute values and retrieve attribute values when instantiating objects in a program.

Uploaded by

api-26570979
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 2

Observation and analysis:

The title of our experiment is “Creating Your Own Classes”. Our


objective in this experiment is to create a class named as AddressBookEntry.
The Following describes the information that an address book entry has.

Attributes/properties Description
 Name Name of the person in the address
book
 Address Address of the person
 Telephone Number Telephone number of the person
 Email Address Person’s email address

We should complete other task such as provide the necessary accessor


and mutator methods for all attributes and create the constructors. And we
should create a class AddressBook that can contain 100 entries of the
AddressBookEntry objects.

In this experiment we used accessor and mutator method. In accessor


we are setting the attributes while in the mutator we are getting the attributes
for the said program. We are doing this kind of method because when we
instantiate in our program it will recognize it other wise there no attributes to
be called and the program will not run. This one of the most error I ever had
in this experiment. I also encounter some problems in basic format in doing
this program. And the importance of the so called mutator and accessor is to
instatiate your classes or methods in the other location.

You might also like