libktorrent
2.2.0
src
peer
authenticationmonitor.h
1
/***************************************************************************
2
* Copyright (C) 2005 by Joris Guisson *
3
* joris.guisson@gmail.com *
4
* *
5
* This program is free software; you can redistribute it and/or modify *
6
* it under the terms of the GNU General Public License as published by *
7
* the Free Software Foundation; either version 2 of the License, or *
8
* (at your option) any later version. *
9
* *
10
* This program is distributed in the hope that it will be useful, *
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13
* GNU General Public License for more details. *
14
* *
15
* You should have received a copy of the GNU General Public License *
16
* along with this program; if not, write to the *
17
* Free Software Foundation, Inc., *
18
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
19
***************************************************************************/
20
#ifndef BTAUTHENTICATIONMONITOR_H
21
#define BTAUTHENTICATIONMONITOR_H
22
23
#include <list>
24
#include <vector>
25
#include <ktorrent_export.h>
26
#include <net/poll.h>
27
28
29
namespace
bt
30
{
31
class
AuthenticateBase;
32
38
class
KTORRENT_EXPORT
AuthenticationMonitor
:
public
net::Poll
39
{
40
std::list<AuthenticateBase*> auths;
41
42
static
AuthenticationMonitor
self
;
43
44
AuthenticationMonitor
();
45
public
:
46
47
~
AuthenticationMonitor
()
override
;
48
49
54
void
add
(
AuthenticateBase
* s);
55
60
void
remove
(
AuthenticateBase
* s);
61
65
void
update
();
66
70
void
clear
();
71
75
void
shutdown
();
76
77
static
AuthenticationMonitor
& instance() {
return
self
;}
78
private
:
79
void
handleData();
80
};
81
82
}
83
84
#endif
bt::AuthenticationMonitor::add
void add(AuthenticateBase *s)
bt::AuthenticationMonitor::clear
void clear()
bt::AuthenticationMonitor::remove
void remove(AuthenticateBase *s)
bt::AuthenticationMonitor::update
void update()
net::Poll
Definition:
poll.h:64
bt::AuthenticateBase
Definition:
authenticatebase.h:43
bt::AuthenticationMonitor::shutdown
void shutdown()
bt::AuthenticationMonitor
Definition:
authenticationmonitor.h:39
Generated by
1.8.20