DBus-1-TQt  1.0
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
TQT_DBusConnectionManager Class Reference
+ Collaboration diagram for TQT_DBusConnectionManager:

Public Member Functions

 TQT_DBusConnectionManager ()
 ~TQT_DBusConnectionManager ()
void bindToApplication ()
TQT_DBusConnectionPrivateconnection (const TQString &name) const
void removeConnection (const TQString &name)
void setConnection (const TQString &name, TQT_DBusConnectionPrivate *c)

Static Public Member Functions

static TQT_DBusConnectionManagerinstance ()

Private Types

typedef TQMap< TQString,
TQT_DBusConnectionPrivate * > 
ConnectionHash

Private Attributes

TQT_DBusConnectionPrivatedefault_connection
ConnectionHash connectionHash

Static Private Attributes

static TQT_DBusConnectionManagermanagerInstance = 0

Detailed Description

Definition at line 36 of file tqdbusconnection.cpp.

Member Typedef Documentation

Definition at line 54 of file tqdbusconnection.cpp.

Constructor & Destructor Documentation

TQT_DBusConnectionManager::TQT_DBusConnectionManager ( )
inline

Definition at line 39 of file tqdbusconnection.cpp.

+ Here is the caller graph for this function:

TQT_DBusConnectionManager::~TQT_DBusConnectionManager ( )

Definition at line 94 of file tqdbusconnection.cpp.

References connectionHash, and default_connection.

{
}
/* FIXME-QT4
for (TQHash<TQString, TQT_DBusConnectionPrivate *>::const_iterator it = connectionHash.constBegin();
it != connectionHash.constEnd(); ++it) {
delete it.value();
}*/
for (ConnectionHash::const_iterator it = connectionHash.constBegin();
it != connectionHash.constEnd(); ++it)
{
delete it.data();
}
connectionHash.clear();
}

Member Function Documentation

void TQT_DBusConnectionManager::bindToApplication ( )

Definition at line 113 of file tqdbusconnection.cpp.

References TQT_DBusConnectionPrivate::bindToApplication(), connectionHash, and default_connection.

{
}
/* FIXME-QT4
for (TQHash<TQString, TQT_DBusConnectionPrivate *>::const_iterator it = connectionHash.constBegin();
it != connectionHash.constEnd(); ++it) {
(*it)->bindToApplication();
}*/
for (ConnectionHash::const_iterator it = connectionHash.constBegin();
it != connectionHash.constEnd(); ++it)
{
it.data()->bindToApplication();
}
}

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

TQT_DBusConnectionPrivate * TQT_DBusConnectionManager::connection ( const TQString &  name) const

Definition at line 66 of file tqdbusconnection.cpp.

References connectionHash, default_connection, and TQT_DBusConnection::default_connection_name.

{
if (name == TQString::fromLatin1(TQT_DBusConnection::default_connection_name))
ConnectionHash::const_iterator it = connectionHash.find(name);
return (it != connectionHash.end() ? it.data() : 0);
}

+ Here is the caller graph for this function:

static TQT_DBusConnectionManager* TQT_DBusConnectionManager::instance ( )
inlinestatic

Definition at line 46 of file tqdbusconnection.cpp.

References managerInstance, and TQT_DBusConnectionManager().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void TQT_DBusConnectionManager::removeConnection ( const TQString &  name)

Definition at line 76 of file tqdbusconnection.cpp.

References connectionHash, default_connection, TQT_DBusConnection::default_connection_name, Atomic::deref(), and TQT_DBusConnectionPrivate::ref.

{
if (name == TQString::fromLatin1(TQT_DBusConnection::default_connection_name)) {
} else {
ConnectionHash::iterator it = connectionHash.find(name);
if (it == connectionHash.end())
return;
d = it.data();
connectionHash.erase(it);
}
if (!d->ref.deref())
delete d;
}

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void TQT_DBusConnectionManager::setConnection ( const TQString &  name,
TQT_DBusConnectionPrivate c 
)

Definition at line 135 of file tqdbusconnection.cpp.

References connectionHash, default_connection, and TQT_DBusConnection::default_connection_name.

{
if (name == TQString::fromLatin1(TQT_DBusConnection::default_connection_name))
else
connectionHash[name] = c;
}

+ Here is the caller graph for this function:

Member Data Documentation

ConnectionHash TQT_DBusConnectionManager::connectionHash
private

Definition at line 55 of file tqdbusconnection.cpp.

TQT_DBusConnectionPrivate* TQT_DBusConnectionManager::default_connection
private

Definition at line 52 of file tqdbusconnection.cpp.

TQT_DBusConnectionManager * TQT_DBusConnectionManager::managerInstance = 0
staticprivate

Definition at line 57 of file tqdbusconnection.cpp.


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