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

HubManager Class Reference

#include <HubManager.h>

Inheritance diagram for HubManager:

List of all members.


Detailed Description

Public hub list, favorites (hub&user). Assumed to be called only by UI thread.

Definition at line 135 of file HubManager.h.


Public Types

enum  HubTypes { TYPE_NORMAL, TYPE_BZIP2 }

Public Member Functions

void addFavorite (const FavoriteHubEntry &aEntry)
bool addFavoriteDir (const string &aDirectory, const string &aName)
void addFavoriteUser (User::Ptr &aUser)
void addListener (Listener *aListener)
UserCommand addUserCommand (int type, int ctx, int flags, const string &name, const string &command, const string &hub)
template<typename T0, class T1, class T2, class T3, class T4, class T5, class T6>
void fire (T0 type, const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4, const T5 &p5, const T6 &p6) throw ()
template<typename T0, class T1, class T2, class T3, class T4, class T5>
void fire (T0 type, const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4, const T5 &p5) throw ()
template<typename T0, class T1, class T2, class T3, class T4>
void fire (T0 type, const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4) throw ()
template<typename T0, class T1, class T2, class T3>
void fire (T0 type, const T1 &p1, const T2 &p2, const T3 &p3) throw ()
template<typename T0, class T1, class T2>
void fire (T0 type, const T1 &p1, const T2 &p2) throw ()
template<typename T0, class T1>
void fire (T0 type, const T1 &p1) throw ()
template<typename T0>
void fire (T0 type) throw ()
StringPairList getFavoriteDirs ()
FavoriteHubEntry * getFavoriteHubEntry (const string &aServer)
FavoriteHubEntry::List & getFavoriteHubs ()
User::List & getFavoriteUsers ()
StringList getHubLists ()
HubTypes getHubListType ()
HubEntry::List getPublicHubs ()
int getSelectedHubList ()
bool getUserCommand (int cid, UserCommand &uc)
UserCommand::List getUserCommands (int ctx, const string &hub, bool op)
UserCommand::List getUserCommands ()
bool isDownloading ()
void load ()
bool moveUserCommand (int cid, int pos)
void refresh ()
void removeFavorite (FavoriteHubEntry *entry)
bool removeFavoriteDir (const string &aName)
void removeFavoriteUser (User::Ptr &aUser)
void removeHubUserCommands (int ctx, const string &hub)
void removeListener (Listener *aListener)
void removeListeners ()
void removeUserCommand (const string &srv)
void removeUserCommand (int cid)
bool renameFavoriteDir (const string &aName, const string &anotherName)
void save ()
bool setHubList (int)
void updateUserCommand (const UserCommand &uc)

Static Public Member Functions

static void deleteInstance ()
static T * getInstance ()
static void newInstance ()

Protected Attributes

CriticalSection listenerCS
ListenerList listeners
ListenerList tmp

Static Protected Attributes

static T * instance = NULL

Private Types

typedef X< 2 > Complete
typedef X< 0 > Data
typedef X< 1 > Failed
typedef X< 0 > Load
typedef map< string,
HubEntry::List > 
PubListMap
typedef X< 3 > Redirected
typedef X< 1 > Save
typedef X< 5 > TypeBZ2
typedef X< 4 > TypeNormal

Private Member Functions

FavoriteHubEntry::Iter getFavoriteHub (const string &aServer)
void load (SimpleXML *aXml)
void loadXmlList (const string &xml)
virtual void on (SettingsManagerListener::Load, SimpleXML *xml) throw ()
virtual void on (TypeBZ2, HttpConnection *) throw ()
virtual void on (TypeNormal, HttpConnection *) throw ()
virtual void on (Redirected, HttpConnection *, const string &) throw ()
virtual void on (Complete, HttpConnection *, const string &) throw ()
virtual void on (Failed, HttpConnection *, const string &) throw ()
virtual void on (Data, HttpConnection *, const u_int8_t *, size_t) throw ()
void onHttpFinished () throw ()

Private Attributes

HttpConnection * c
CriticalSection cs
bool dontSave
string downloadBuf
StringPairList favoriteDirs
FavoriteHubEntry::List favoriteHubs
int lastId
int lastServer
HubTypes listType
PubListMap publicListMatrix
string publicListServer
bool running
UserCommand::List userCommands
User::List users

Friends

class Singleton< HubManager >

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

Generated by  Doxygen 1.6.0   Back to index