-
Notifications
You must be signed in to change notification settings - Fork 1
/
AnnounceInfo.h
53 lines (49 loc) · 1.16 KB
/
AnnounceInfo.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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#ifndef ANNOUNCEINFO_H
#define ANNOUNCEINFO_H
#include <string>
class AnnounceInfo
{
public:
AnnounceInfo(std::string ipa_, std::string infoHash_, std::string peerId_, std::string torrentPass_,
int event_, int port_, uint64_t downloaded_, uint64_t left_, uint64_t uploaded_);
~AnnounceInfo();
void setTorrentId(int torrentId_);
void setClientId(int clientId_);
void setUserId(int userId_);
void setIpaId(int ipaId_);
void setOldUpload(uint64_t oldUpload_);
void setOldDownload(uint64_t oldDownload_);
std::string getTorrentPass();
std::string getIpa();
std::string getInfoHash();
std::string getPeerId();
int getUserId();
int getPort();
int getTorrentId();
int getEvent();
int getClientId();
int getIpaId();
uint64_t getDownloaded();
uint64_t getUploaded();
uint64_t getLeft();
uint64_t getOldUpload();
uint64_t getOldDownload();
private:
std::string ipa;
std::string infoHash;
std::string peerId;
std::string torrentPass;
int port;
int event;
uint64_t downloaded;
uint64_t left;
uint64_t uploaded;
//Information from the database
int clientId;
int torrentId;
int userId;
int ipaId;
uint64_t oldUpload = 0;
uint64_t oldDownload = 0;
};
#endif