Home · All Namespaces · All Classes · Grouped Classes · Modules · Functions codeless banner

QtopiaIpcEnvelope Class Reference
[QtBaseModule]

The QtopiaIpcEnvelope class encapsulates and sends QCop messages. More...

    #include <QtopiaIpcEnvelope>

Inherits QDataStream.

Public Functions


Detailed Description

The QtopiaIpcEnvelope class encapsulates and sends QCop messages.

QCop messages allow applications to communicate with each other by sending messages using QtopiaIpcEnvelope and receiving messages by connecting to a QtopiaChannel.

To send a message, use the following protocol:

    QtopiaIpcEnvelope e(channelname, messagename);
    e << parameter1 << parameter2 << ...;

For messages without parameters, simply use:

    QtopiaIpcEnvelope e(channelname, messagename);

where:

Note: Do not try to simplify this further as it may confuse some compilers.

To receive a message either:

See also: Qt Extended IPC and Services.

Consider using QtopiaIpcAdaptor or QtopiaServiceRequest instead of QtopiaIpcEnvelope, as they provide a better interface for sending QCop messages.

See also QtopiaChannel, QtopiaIpcAdaptor, and QtopiaServiceRequest.


Member Function Documentation

QtopiaIpcEnvelope::QtopiaIpcEnvelope ( const QString & channel, const QString & message )

Constructs a QtopiaIpcEnvelope to write message to channel. If message has parameters then use operator<<() to add the parameters to the envelope.

QtopiaIpcEnvelope::~QtopiaIpcEnvelope ()

Writes the message and then destroys the QtopiaIpcEnvelope.


Copyright © 2009 Nokia Trademarks
Qt Extended 4.4.3