d00 ex01 phonebook resolu pbms
This commit is contained in:
@@ -14,16 +14,24 @@ Contact::~Contact( void ) {
|
||||
}
|
||||
|
||||
// ADD
|
||||
void Contact::add_first( std::string str ) {this->first.assign(str);}
|
||||
void Contact::add_last( std::string str ) {this->last.assign(str);}
|
||||
void Contact::add_nick( std::string str ) {this->nick.assign(str);}
|
||||
void Contact::add_num( std::string str ) {this->num.assign(str);}
|
||||
void Contact::add_secret( std::string str ) {this->secret.assign(str);}
|
||||
void Contact::add_first( std::string str ) {this->_first.assign(str);}
|
||||
void Contact::add_last( std::string str ) {this->_last.assign(str);}
|
||||
void Contact::add_nick( std::string str ) {this->_nick.assign(str);}
|
||||
void Contact::add_num( std::string str ) {this->_num.assign(str);}
|
||||
void Contact::add_secret( std::string str ) {this->_secret.assign(str);}
|
||||
|
||||
// GET
|
||||
std::string Contact::get_first( void ) {return first;}
|
||||
std::string Contact::get_last( void ) {return last;}
|
||||
std::string Contact::get_nick( void ) {return nick;}
|
||||
std::string Contact::get_num( void ) {return num;}
|
||||
std::string Contact::get_secret( void ) {return secret;}
|
||||
std::string Contact::get_first( void ) {return _first;}
|
||||
std::string Contact::get_last( void ) {return _last;}
|
||||
std::string Contact::get_nick( void ) {return _nick;}
|
||||
std::string Contact::get_num( void ) {return _num;}
|
||||
std::string Contact::get_secret( void ) {return _secret;}
|
||||
|
||||
// CLEAR
|
||||
void Contact::clear_contact() {
|
||||
this->_first.clear();
|
||||
this->_last.clear();
|
||||
this->_nick.clear();
|
||||
this->_num.clear();
|
||||
this->_secret.clear();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user