Advertisement
CamolaZ

Cliente.cpp

May 20th, 2016
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.78 KB | None | 0 0
  1. #pragma once
  2.  
  3. #include <iostream>
  4. #include <fstream>
  5. #include <string>
  6.  
  7. #include "Data.h"
  8.  
  9. using namespace std;
  10.  
  11.  
  12. class Cliente {
  13.  private:
  14.   unsigned int id;
  15.   string nome;
  16.   Data cartaoCliente;
  17.   float volCompras;
  18.  
  19.  public:
  20.      //Cliente();
  21.   Cliente(ifstream & in);
  22.   string getNome() const;
  23.   string getData() const;
  24.   float getVolCompras() const;
  25.   unsigned int getId() const;
  26.   void setId(string idRead);
  27.   void setNome(string nameRead);
  28.   void setVolCompras(string amountRead);
  29.   void save(ofstream & out) const;
  30.   ostream& operator<<(ostream& out);  // mostra informacao do cliente no ecra
  31.   friend bool operator<(const Cliente &cli1, const Cliente &cli2); // compara 2 clientes (1 cleinte e menor que outro se o seu nome for "alfabeticamente" inferior)
  32.  
  33. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement