Subversion Repository Public Repository

Fangh

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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#include "enigme.h"

Enigme::Enigme(){
    nbReponse = 0;
    enigmeJoue = false;
}

Enigme::Enigme(std::string _enonce): enonce(_enonce)
{
    nbReponse = 0;
    enigmeJoue = false;
}

void Enigme::ajouterEnonce(std::string _enonce){
    enonce = _enonce;
}

void Enigme::ajouterReponse(std::string _reponse){
    nbReponse++;
    listeReponse.push_back(_reponse);
}

void Enigme::ajouterCompetence(std::string _competence){
    competence = _competence;
}

void Enigme::setEnigmeJoue(bool joue){
    enigmeJoue = joue;
}

std::string Enigme::getEnonce() const{
    return enonce;
}

int Enigme::getNbReponse() const{
    return nbReponse;
}

const std::list<std::string> * Enigme::getListeReponse() const{
    return (const std::list<std::string>*)(&listeReponse);
}

bool Enigme::getEnigmeJoue() const{
    return enigmeJoue;
}

std::string Enigme::afficherInfo() const{
    std::string chaineRetour = "";

    chaineRetour += this->getEnonce() + "\n";
    return chaineRetour;
}

std::string Enigme::getCompetence() const{
    return competence;
}

Commits for Fangh/trunk/enigme.cpp

Diff revisions: vs.
Revision Author Commited Message
43 Diff Diff thanoc picture thanoc Fri 05 Mar, 2010 01:30:34 +0000
34 thanoc picture thanoc Wed 03 Mar, 2010 14:31:27 +0000