error: no matching function for call to 'Emprunt::setClient(Client&)'
Salut, je n'arrive pas à régler cette erreur voici mon code
Emprunt.hpp :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
|
#include <iostream>
#include <vector>
#include <string>
#include "Velo.hpp"
#include "Client.hpp"
using namespace std;
#ifndef Emprunt_hpp
#define Emprunt_hpp
class Emprunt
{
protected:
Velo *leVeloEmprunter;
Client *emprunteur;
bool enCours;
public:
Emprunt();
Emprunt(Velo *, Client *, bool);
Emprunt(const Emprunt &);
void getVelo();
void setVelo(Velo *);
void getClient();
void setClient(Client*);
bool getEnCours();
bool setEnCours(bool);
void afficherEp();
};
#endif /* Emprunt_hpp */ |
Le code de ma méthode concernée
Emprunt.cpp :
Code:
1 2 3 4
|
void Emprunt::setClient(Client * c){
emprunteur = c;
} |
main.cpp :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
|
#include <iostream>
#include <fstream>
#include "GestionVelos.hpp"
#include "Velo.hpp"
#include "Client.hpp"
#include <string>
#include "Emprunt.hpp"
using namespace std;
int main(void)
{
Emprunt e;
Client c2;
e.afficherEp();
e.setClient(c2);
e.afficherEp();
return 0;
} |
Voila j'attends de voir vos retour merci d'avance.