For this assignment, you will not be turning in a complete program.
You will build a class called Rolodex, which contains appropriate public
methods for operating on an electronic Rolodex.
Method | Description |
bool Rolodex::insert_card(string last_name, string phone); | Insert the person into the Rolodex, immediately after the current card. Set the current card to now be the new card. If the Rolodex is full, return false; otherwise, return true. |
bool Rolodex::get_current_name(string &last_name); | Provide the last name on the current card. If no current card has been set by the user, return false; otherwise, return true. |
bool Rolodex::get_current phone(string &phone); | Provide the phone number on the current card. If no current card has been set by the user, return false; otherwise, return true. |
bool Rolodex::set_next_current_card(); | Set the current card to be the next card in the Rolodex. If the current card is the last card, the next card should be the first one (this is a circular Rolodex). If there is only one card, the next card is the same card. If there are no cards in the Rolodex, this method should return false; otherwise, return true. |
bool Rolodex::delete_current_card(); | Delete the current card from the Rolodex, and set the current card to be the next card in the Rolodex. If this card is the last card in the Rolodex, no card should be the current card. If no cards were present in the Rolodex, return false; otherwise return true. |