QJsonChannelCore
QJsonChannelService.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <QObject>
4 #include <QByteArray>
5 #include <QSharedPointer>
6 
7 #include "QJsonChannelMessage.h"
8 
9 class QJsonChannelServicePrivate;
10 
16 public:
26  QJsonChannelService (const QByteArray& name, const QByteArray& version, const QByteArray& description, QSharedPointer<QObject> obj,
27  bool serviceObjIsThreadSafe);
29 
35  QSharedPointer<QObject> serviceObj ();
36 
42  const QByteArray& serviceName () const;
43 
50  const QJsonObject& serviceInfo () const;
51 
58  QJsonChannelMessage dispatch (const QJsonChannelMessage& request) const;
59 
60 private:
61  Q_DISABLE_COPY (QJsonChannelService)
62  Q_DECLARE_PRIVATE (QJsonChannelService)
63 
64 #if !defined(USE_QT_PRIVATE_HEADERS)
65  QScopedPointer<QJsonChannelServicePrivate> d_ptr;
66 #endif
67 };
Service wrapper over QOblect is responsible for QObjects methods ivocation according to JSON-RPC requ...
Representation of JSON-RPC message.
#define QJSONCHANNELCORE_EXPORT