Example #1
0
DummyPresenceControl::DummyPresenceControl(const QString &service, QObject *parent,
                                           QAbstractIpcInterface::Mode mode)
                : QAbstractIpcInterface( "/Communications", "DummyPresenceControl",
                                 service, parent, mode )
{
    proxyAll(staticMetaObject);
}
Example #2
0
/*!
    Construct a new vibrate abstraction object for provider \a id and attaches
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a id is empty, this class will use the first available
    provider that supports the vibrate interface.  If there is more
    than one service that supports the vibrate interface, the caller
    should enumerate them with QHardwareManager::providers()
    and create separate QVibrateAccessory objects for each.

    \sa QHardwareManager::providers()
*/
QVibrateAccessory::QVibrateAccessory
        ( const QString& id, QObject *parent,
          QAbstractIpcInterface::Mode mode )
    : QHardwareInterface( "QVibrateAccessory", id, parent, mode )
{
    proxyAll( staticMetaObject );
}
Example #3
0
/*!
    Construct a new presence monitoring object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.
*/
QPresence::QPresence( const QString& service, QObject *parent,
                      QCommInterface::Mode mode )
    : QCommInterface( "QPresence", service, parent, mode )
{
    proxyAll( staticMetaObject );
    d = new QPresencePrivate();
}
Example #4
0
/*!
    Construct a new message waiting status object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a service is empty, this class will use the first available
    service that supports message waiting.  If there is more
    than one service that supports message waiting, the caller
    should enumerate them with QCommServiceManager::supports()
    and create separate QMessageWaiting objects for each.

    \sa QCommServiceManager::supports()
*/
QMessageWaiting::QMessageWaiting
        ( const QString& service, QObject *parent, QCommInterface::Mode mode )
    : QCommInterface( "QMessageWaiting", service, parent, mode )
{
    proxyAll( staticMetaObject );
    d = new QMessageWaitingPrivate();
    if ( mode == Client )
        d->generation = -1;
    else
        d->generation = 0;
}
MediaContentServer::MediaContentServer
(
 QMediaServerSession* session,
 QMediaHandle const& handle
):
    QMediaAbstractControlServer(handle, "Session"),
    d(new MediaContentServerPrivate)
{
    d->session = session;

    setValue("controls", d->session->interfaces() << "Session");

    connect(d->session, SIGNAL(interfaceAvailable(QString)),
            this, SLOT(interfaceAvailable(QString)));

    connect(d->session, SIGNAL(interfaceUnavailable(QString)),
            this, SLOT(interfaceUnavailable(QString)));

    proxyAll();
}
/*!
    Sets up remote invocation proxies for all signals and public slots
    on this object, starting at the class specified by \a meta.
    Also register \a subInterfaceName as a sub-interface name for
    this object's primary interface name.  After this call,
    interfaceName() will return \a subInterfaceName.
*/
void QAbstractIpcInterface::proxyAll
        ( const QMetaObject& meta, const QString& subInterfaceName )
{
    proxyAll( meta );
    d->realInterfaceName = subInterfaceName;
    if ( d->mode == Server ) {

        // Add extra information under "/Communications/Interfaces"
        // to redirect clients to the original interface channels.
        QString path = d->valueSpaceLocation + "/_channels/" + subInterfaceName + "/" +
                       d->groupName;
        QString requestChannel = "QPE" + d->valueSpaceLocation + "/" +
                                 d->interfaceName + "/Request/" + d->groupName;
        QString responseChannel = "QPE" + d->valueSpaceLocation + "/" +
                                 d->interfaceName + "/Response/" + d->groupName;
        QValueSpaceObject *values = new QValueSpaceObject( path, this );
        values->setAttribute( QString(".requestChannel"), requestChannel );
        values->setAttribute( QString(".responseChannel"), responseChannel );
        values->setAttribute( QString(".valuePath"), d->path );

    } else if ( d->mode == Client ) {

        // Verify that there is a registration for the new interface name
        // that points back to the primary interface name.
        QValueSpaceItem item( d->valueSpaceLocation + "/_channels/" +
                              subInterfaceName + "/" + d->groupName );
        QString path = item.value( ".valuePath" ).toString();
        if ( path != d->path ) {
            qWarning( "QAbstractIpcInterface: %s is not a sub-interface of %s",
                      subInterfaceName.toLatin1().constData(),
                      d->interfaceName.toLatin1().constData() );
            QTimer::singleShot( 0, this, SIGNAL(disconnected()) );
            d->mode = Invalid;
        }

    }
}
/*!
    Construct a new GPRS network registration object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a service is empty, this class will use the first available
    service that supports GPRS network registration.  If there is more
    than one service that supports GPRS network registration, the caller
    should enumerate them with QCommServiceManager::supports()
    and create separate QGprsNetworkRegistration objects for each.

    \sa QCommServiceManager::supports()
*/
QGprsNetworkRegistration::QGprsNetworkRegistration
        ( const QString& service, QObject *parent, QCommInterface::Mode mode )
    : QCommInterface( "QGprsNetworkRegistration", service, parent, mode )
{
    proxyAll( staticMetaObject );
}
Example #8
0
/*!
    Construct a new cell broadcast handling object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a service is empty, this class will use the first available
    service that supports cell broadcast.  If there is more
    than one service that supports cell broadcast, the caller
    should enumerate them with QCommServiceManager::supports()
    and create separate QCellBroadcast objects for each.

    \sa QCommServiceManager::supports()
*/
QCellBroadcast::QCellBroadcast
        ( const QString& service, QObject *parent, QCommInterface::Mode mode )
    : QCommInterface( "QCellBroadcast", service, parent, mode )
{
    proxyAll( staticMetaObject );
}
Example #9
0
/*!
    Construct a new call forwarding object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a service is empty, this class will use the first available
    service that supports call forwarding.  If there is more than one
    service that supports call forwarding, the caller should enumerate
    them with QCommServiceManager::supports() and create separate
    QCallForwarding objects for each.

    \sa QCommServiceManager::supports()
*/
QCallForwarding::QCallForwarding( const QString& service, QObject *parent,
                                  QCommInterface::Mode mode )
    : QCommInterface( "QCallForwarding", service, parent, mode )
{
    proxyAll( staticMetaObject );
}
Example #10
0
/*!
    Construct a new advice of charge object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a service is empty, this class will use the first available
    service that supports advice of charge.  If there is more
    than one service that supports advice of charge, the caller
    should enumerate them with QCommServiceManager::supports()
    and create separate QAdviceOfCharge objects for each.

    \sa QCommServiceManager::supports()
*/
QAdviceOfCharge::QAdviceOfCharge
        ( const QString& service, QObject *parent, QCommInterface::Mode mode )
    : QCommInterface( "QAdviceOfCharge", service, parent, mode )
{
    proxyAll( staticMetaObject );
}
Example #11
0
/*!
    Construct a new call settings object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a service is empty, this class will use the first available
    service that supports call settings.  If there is more than one
    service that supports call settings, the caller should enumerate
    them with QCommServiceManager::supports() and create separate
    QCallSettings objects for each.

    \sa QCommServiceManager::supports()
*/
QCallSettings::QCallSettings( const QString& service, QObject *parent,
                              QCommInterface::Mode mode )
    : QCommInterface( "QCallSettings", service, parent, mode )
{
    proxyAll( staticMetaObject );
}
QBluetoothAudioGateway::QBluetoothAudioGateway(const QString &service,
QObject *parent,
QAbstractIpcInterface::Mode mode) : QCommInterface("QBluetoothAudioGateway", service, parent, mode)
{
    proxyAll( staticMetaObject );
}
Example #13
0
/*!
    Constructs a new QUsbStorageGadget object in \a group and attach it to
    \a parent.  If \a mode is \c Client, then the object is constructed in
    client mode and \a group may be empty to indicate that the default group
    should be used.
*/
QUsbStorageGadget::QUsbStorageGadget(const QString &group, QObject *parent,
                                     QAbstractIpcInterface::Mode mode)
    : QUsbGadget("QUsbStorageGadget", group, parent, mode)
{
    proxyAll(staticMetaObject);
}
Example #14
0
/*!
    Construct a new SIM file access object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a service is empty, this class will use the first available
    service that supports SIM file access.  If there is more
    than one service that supports SIM file access, the caller
    should enumerate them with QCommServiceManager::supports()
    and create separate QSimFiles objects for each.

    Normally this constructor would not be used by client applications.
    Client applications should use QBinarySimFile and QRecordBasedSimFile.
    Server applications should inherit from the QSimFiles class and
    call this constructor with \a mode set to QCommInterface::Server.

    \sa QCommServiceManager::supports()
*/
QSimFiles::QSimFiles( const QString& service, QObject *parent,
                      QCommInterface::Mode mode )
    : QCommInterface( "QSimFiles", service, parent, mode )
{
    proxyAll( staticMetaObject );
}
Example #15
0
/*!
    Construct a new phone RF functionality object for \a service and attach
    it to \a parent.  The object will be created in client mode if
    \a mode is Client, or server mode otherwise.

    If \a service is empty, this class will use the first available
    service that supports phone RF functionality.  If there is more
    than one service that supports phone RF functionality, the caller
    should enumerate them with QCommServiceManager::supports()
    and create separate QPhoneRfFunctionality objects for each.

    \sa QCommServiceManager::supports()
*/
QPhoneRfFunctionality::QPhoneRfFunctionality
        ( const QString& service, QObject *parent, QCommInterface::Mode mode )
    : QCommInterface( "QPhoneRfFunctionality", service, parent, mode )
{
    proxyAll( staticMetaObject );
}