Qt 4.8
Protected Functions | List of all members
QDBusPendingReplyData Class Reference

#include <qdbuspendingreply.h>

Inheritance diagram for QDBusPendingReplyData:
QDBusPendingCall

Protected Functions

QVariant argumentAt (int index) const
 
void assign (const QDBusPendingCall &call)
 
void assign (const QDBusMessage &message)
 
 QDBusPendingReplyData ()
 
void setMetaTypes (int count, const int *metaTypes)
 
 ~QDBusPendingReplyData ()
 
- Protected Functions inherited from QDBusPendingCall
 QDBusPendingCall (QDBusPendingCallPrivate *dd)
 

Additional Inherited Members

- Public Functions inherited from QDBusPendingCall
QDBusPendingCalloperator= (const QDBusPendingCall &other)
 Creates a copy of the other pending asynchronous call and drops the reference to the previously-referenced call. More...
 
 QDBusPendingCall (const QDBusPendingCall &other)
 Creates a copy of the other pending asynchronous call. More...
 
 ~QDBusPendingCall ()
 Destroys this copy of the QDBusPendingCall object. More...
 
- Static Public Functions inherited from QDBusPendingCall
static QDBusPendingCall fromCompletedCall (const QDBusMessage &message)
 Creates a QDBusPendingCall object based on the message msg. More...
 
static QDBusPendingCall fromError (const QDBusError &error)
 Creates a QDBusPendingCall object based on the error condition error. More...
 
- Protected Variables inherited from QDBusPendingCall
QExplicitlySharedDataPointer< QDBusPendingCallPrivated
 

Detailed Description

Definition at line 58 of file qdbuspendingreply.h.

Constructors and Destructors

◆ QDBusPendingReplyData()

QDBusPendingReplyData::QDBusPendingReplyData ( )
protected

Definition at line 283 of file qdbuspendingreply.cpp.

284  : QDBusPendingCall(0) // initialize base class empty
285 {
286 }

◆ ~QDBusPendingReplyData()

QDBusPendingReplyData::~QDBusPendingReplyData ( )
protected

Definition at line 288 of file qdbuspendingreply.cpp.

289 {
290 }

Functions

◆ argumentAt()

QVariant QDBusPendingReplyData::argumentAt ( int  index) const
protected

Definition at line 303 of file qdbuspendingreply.cpp.

Referenced by QDBusPendingReply< T1, T2, T3, T4, T5, T6, T7, T8 >::argumentAt().

304 {
305  if (d)
306  d->waitForFinished(); // bypasses "const"
307 
308  Q_ASSERT_X(d && index >= 0 && index < d->replyMessage.arguments().count(),
309  "QDBusPendingReply::argumentAt",
310  "Index out of bounds");
311 
312  return d->replyMessage.arguments().at(index);
313 }
QExplicitlySharedDataPointer< QDBusPendingCallPrivate > d
QList< QVariant > arguments() const
Returns the list of arguments that are going to be sent or were received from D-Bus.
const T & at(int i) const
Returns the item at index position i in the list.
Definition: qlist.h:468
#define Q_ASSERT_X(cond, where, what)
Definition: qglobal.h:1837
quint16 index

◆ assign() [1/2]

void QDBusPendingReplyData::assign ( const QDBusPendingCall call)
protected

Definition at line 292 of file qdbuspendingreply.cpp.

Referenced by QDBusPendingReply< T1, T2, T3, T4, T5, T6, T7, T8 >::assign().

293 {
295 }
QDBusPendingCall & operator=(const QDBusPendingCall &other)
Creates a copy of the other pending asynchronous call and drops the reference to the previously-refer...

◆ assign() [2/2]

void QDBusPendingReplyData::assign ( const QDBusMessage message)
protected

Definition at line 297 of file qdbuspendingreply.cpp.

298 {
299  d = new QDBusPendingCallPrivate(QDBusMessage(), 0); // drops the reference to the old one
300  d->replyMessage = message;
301 }
friend class QDBusPendingCallPrivate
QExplicitlySharedDataPointer< QDBusPendingCallPrivate > d
The QDBusMessage class represents one message sent or received over the D-Bus bus.
Definition: qdbusmessage.h:59

◆ setMetaTypes()

void QDBusPendingReplyData::setMetaTypes ( int  count,
const int *  metaTypes 
)
protected

Definition at line 315 of file qdbuspendingreply.cpp.

316 {
317  Q_ASSERT(d);
318  QMutexLocker locker(&d->mutex);
319  d->setMetaTypes(count, types);
321 }
#define Q_ASSERT(cond)
Definition: qglobal.h:1823
QExplicitlySharedDataPointer< QDBusPendingCallPrivate > d
void setMetaTypes(int count, const int *types)
The QMutexLocker class is a convenience class that simplifies locking and unlocking mutexes...
Definition: qmutex.h:101
static const struct @32 types[]

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