Billing program for the appliance repair company Seoane.
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

at main 111 lines 1.7 kB view raw
1#include "Cliente.h" 2#include <string> 3using namespace std; 4 5Cliente::Cliente() 6{ 7nombre = ""; 8apellidos=""; 9direccion=""; 10poblacion=""; 11nif=""; 12codigo = -1; 13historico = false; 14} 15 16Cliente::~Cliente() 17{ 18} 19//metodos get 20 21int Cliente::getid(){ 22 return id; 23} 24 25int Cliente::getcodigo(){ 26 return codigo; 27} 28 29string Cliente::getnombre(){ 30 return nombre; 31} 32 33string Cliente::getapellidos(){ 34 return apellidos; 35} 36 37string Cliente::getdireccion(){ 38 return direccion; 39} 40 41string Cliente::getnif(){ 42 return nif; 43} 44 45string Cliente::getpoblacion(){ 46 return poblacion; 47} 48 49bool Cliente::gethistorico() { 50 return historico; 51} 52 53list<int> Cliente::gettelefonos() { 54 return telefonos; 55} 56 57//metodos set 58 59void Cliente::setid(int ident){ 60 id=ident; 61} 62 63void Cliente::setcodigo(int cod){ 64 codigo=cod; 65} 66 67void Cliente::setnombre(string nom){ 68 nombre=nom; 69} 70 71void Cliente::setapellidos(string apell){ 72 apellidos=apell; 73} 74 75void Cliente::setdireccion(string dir){ 76 direccion=dir; 77} 78 79void Cliente::setnif(string ni){ 80 nif=ni; 81} 82 83void Cliente::setpoblacion(string pob){ 84 poblacion=pob; 85} 86 87void Cliente::sethistorico(bool h) { 88 historico = h; 89} 90 91void Cliente::settelefonos(list<int> t) { 92 telefonos = t; 93} 94 95//sobrecarga del operador = 96 97Cliente Cliente::operator=(Cliente c){ 98 99 if (this != &c) { 100 this->id = c.getid(); 101 this->codigo = c.getcodigo(); 102 this->nombre = c.getnombre(); 103 this->apellidos = c.getapellidos(); 104 this->direccion = c.getdireccion(); 105 this->nif = c.getnif(); 106 this->poblacion = c.getpoblacion(); 107 this->historico = c.gethistorico(); 108 this->telefonos = c.gettelefonos(); 109 } 110 return *this; 111}