QIviServiceInterface Class

Defines the interface for services. More...

Header: #include <QIviServiceInterface>
qmake: QT += ivicore
Inherited By:

QIviServiceObject

Public Functions

virtual ~QIviServiceInterface()
virtual QIviFeatureInterface *interfaceInstance(const QString &interfaceName) const = 0
virtual QStringList interfaces() const = 0
T qivi_interface_cast(QObject *backend)

Detailed Description

The QIviServiceInterface class defines the interface for services registered with QIviServiceManager.

Typically, service objects inherit the concrete class, QIviServiceObject, instead of using QIviServiceInterface directly.

See also QIviServiceObject.

Member Function Documentation

[virtual] QIviServiceInterface::~QIviServiceInterface()

Destructs the QIviServiceInterface instance.

[pure virtual] QIviFeatureInterface *QIviServiceInterface::interfaceInstance(const QString &interfaceName) const

Returns an object implementing the service interface requested through interfaceName.

[pure virtual] QStringList QIviServiceInterface::interfaces() const

Returns a list of service interface names supported by the service object instance.

Related Non-Members

template <typename T> T qivi_interface_cast(QObject *backend)

Casts the given backend to the interface type T.

When implementing a QtIvi Feature, use this function as it shows a meaningful error message when the cast fails.

See also qobject_cast.