Logo Search packages:      
Sourcecode: dc-qt version File versions  Download package

dcqt_backend::SessionManager Class Reference

#include <SessionManager.h>

Inheritance diagram for dcqt_backend::SessionManager:

List of all members.


Detailed Description

Provides mapping between dc++ Client objects and our own Session's.

Definition at line 26 of file SessionManager.h.


Public Types

typedef X< 2 > ClientConnected
typedef X< 4 > ClientDisconnected
typedef X< 3 > ClientUpdated
typedef X< 1 > DownloadFailed
typedef X< 2 > DownloadFinished
typedef X< 0 > DownloadStarting
typedef X< 3 > FavoriteAdded
typedef X< 4 > FavoriteRemoved
typedef X< 1 > IncomingSearch
typedef hash_map< int,::User::PtrIntUserPtrMap
 Used to map requests from the gui to a user, for example when clicking in the transfer view.
typedef X< 1 > Minute
typedef X< 0 > Second
typedef X< 5 > UserAdded
typedef map< ::User::Ptr,
dcqt_backend::User > 
UserPtrUserMap
 Used to cache backend::User structs.
typedef X< 6 > UserRemoved
typedef X< 0 > UserUpdated

Public Member Functions

void addFavouriteHub (FavoriteHubEntry &entry)
void closeSession (int)
int createSession (const string &url)
int generateUserId ()
FavoriteHubEntry::List & getFavouriteHubs ()
HubEntry::List getPublicHubs ()
Session * getSession (Client *)
Session * getSession (int)
map< int, Session * > * getSessionMap ()
IntUserPtrMapgetUserIdMap ()
UserPtrUserMapgetUserPtrMap ()
virtual void on (UserAdded, const User::Ptr &) throw ()
virtual void on (IncomingSearch, const string &) throw ()
virtual void on (UserUpdated, const User::Ptr &) throw ()
virtual void on (HubManagerListener::FavoriteRemoved, const FavoriteHubEntry *) throw ()
virtual void on (HubManagerListener::FavoriteAdded, const FavoriteHubEntry *) throw ()
virtual void on (HubManagerListener::DownloadFinished, const string &) throw ()
virtual void on (HubManagerListener::DownloadFailed, const string &) throw ()
virtual void on (HubManagerListener::DownloadStarting, const string &) throw ()
virtual void on (TimerManagerListener::Second, u_int32_t) throw ()
virtual void on (ClientManagerListener::ClientDisconnected, Client *c) throw ()
virtual void on (ClientManagerListener::ClientUpdated, Client *c) throw ()
virtual void on (ClientManagerListener::ClientConnected, Client *c) throw ()
void refreshHublist ()
void removeFavouriteHub (string &server)

Static Public Member Functions

static SessionManagerinstance ()

Public Attributes

boost::recursive_mutex sessionLock

Private Types

typedef map< Client *, Session * > ClientSessionMap
typedef map< int, Session * > IntSessionMap

Private Attributes

ClientSessionMap clientSessionMap
int64_t hashBytesStart
bool hashingCompleted
IntSessionMap intSessionMap
int sessionIdCounter
int userIdCounter
IntUserPtrMap userIdMap
Stack< int > userIdStack
UserPtrUserMap userPtrMap

Static Private Attributes

static SessionManagerinst = 0

The documentation for this class was generated from the following files:

Generated by  Doxygen 1.6.0   Back to index