Question: 3 . The Address class: - Member Variables - a string that holds the street name - street - a string that holds the city
The Address class:
Member Variables
a string that holds the street name street
a string that holds the city name city
a string that holds the state name state
a sizet that holds the zip code zipcode
Constructors
a default constructor that takes no parameters.
a parameterized constructor that takes values for each member variable in the above order to create an Address object.
Member FunctionsMethods
Getters & Setters aka Mutators & Accessors for each member variable in total
Notice that in setDOB you will using parameters to build a new Date object but in the constructor, an existing Date object will be passed.
All string variables will have values stored in uppercase only.
The operator function takes istrean& for cin and Address& for Address object as parameters and returns istreans for cin It will be declared as a friend of Address class.
The overloaded operator sets the values for all member variables using user input. The Autograder will send inputs in the following sequence. As always, the aren't included in the actual inputs. A new line indicates that the enterreturn key has been pressed:
STREET
Be extra careful managing your input stream!
The operator function takes ostream for cout and Address& for Address object as parameters and returns ostream& for cout The overloaded operator displays the Address object in format specified below. It will be declared as a friend of Address class.
the output must match the following format exactly! What is between the will be your member variables. Do not indude the characters in your output. Be sure to end each line.
The left side of the because will be a field of characters, then the colon character then a field of characters for a total of characters.
STREET
CITY
STATE
ZIP CODE
zip
The Pet class:
Member Variables
a string that holds the pet name name
a date that holds the date of birth DOB
a string that holds the pet type type
a string that holds the breed breed
Constructors
a default constructor that takes no parameters.
a full parameterized constructor that takes values for each member variable in the above order to create a Pet object. Use constructor for Date class to set DoB
Member FunctionsMethods
Getters & Setters aka Mutators & Accessors for each member variable in total
All string variables will have values stored in uppercase only.
settype will take a const int & as input and sets the type using below values should implement using switchcase only
: DOG
: CAT
: BIRD
: SNAKE
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
