1// Copyright (C) 2017 Ford Motor Company
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QREGISTRYSOURCE_P_H
5#define QREGISTRYSOURCE_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include "qtremoteobjectglobal.h"
19#include "private/qglobal_p.h"
20
21#include <QtCore/qobject.h>
22
23QT_BEGIN_NAMESPACE
24
25class QRegistrySource : public QObject
26{
27 Q_OBJECT
28 Q_CLASSINFO(QCLASSINFO_REMOTEOBJECT_TYPE, "Registry")
29
30 Q_PROPERTY(QRemoteObjectSourceLocations sourceLocations READ sourceLocations)
31
32public:
33 explicit QRegistrySource(QObject *parent = nullptr);
34 ~QRegistrySource() override;
35
36 QRemoteObjectSourceLocations sourceLocations() const;
37
38Q_SIGNALS:
39 void remoteObjectAdded(const QRemoteObjectSourceLocation &entry);
40 void remoteObjectRemoved(const QRemoteObjectSourceLocation &entry);
41
42public Q_SLOTS:
43 void addSource(const QRemoteObjectSourceLocation &entry);
44 void removeSource(const QRemoteObjectSourceLocation &entry);
45 void removeServer(const QUrl &url);
46
47private:
48 QRemoteObjectSourceLocations m_sourceLocations;
49};
50
51QT_END_NAMESPACE
52
53#endif
54

source code of qtremoteobjects/src/remoteobjects/qremoteobjectregistrysource_p.h