-
Notifications
You must be signed in to change notification settings - Fork 0
/
bot.h
40 lines (37 loc) · 1.01 KB
/
bot.h
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
/*
* bot.h
*
* Created on: 06/09/2012
* Author: rafa
*/
#ifndef BOT_H_
#define BOT_H_
#include <iostream>
#include <string>
#include <vector>
#include <pthread.h>
using namespace std;
typedef std::vector<string>::iterator vec_iter;
class bot {
private:
string Nombre;
vec_iter inicio;
vec_iter fin;
vector<string>* dicc;
vector<string>* intentos;
pthread_mutex_t* consola;
pthread_mutex_t* diccIntentos;
void enviarMsj(string msj);
public:
bot();
bot(string n, vector<string> *dicc, vector<string> *inten, pthread_mutex_t* c,pthread_mutex_t* di);
void inicializar(string n, vector<string> *dicc, vector<string> *inten, pthread_mutex_t* c,pthread_mutex_t* di);
bot(string n, vector<string> *dicc, vec_iter inicio, vec_iter fin, pthread_mutex_t* c,pthread_mutex_t* di);
void inicializar(string n, vector<string> *dicc, vec_iter inicio, vec_iter fin, pthread_mutex_t* c,pthread_mutex_t* di);
void buscar();
void buscarAlt();
bool comparar(int k);
virtual ~bot();
};
#include "bot.cpp"
#endif /* BOT_H_ */