Qt
6.x
The Qt SDK
Loading...
Searching...
No Matches
qdbusxmlparser_p.h
Go to the documentation of this file.
1
// Copyright (C) 2016 The Qt Company Ltd.
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 QDBUSXMLPARSER_P_H
5
#define QDBUSXMLPARSER_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 for the convenience
12
// of the QLibrary class. This header file may change from
13
// version to version without notice, or even be removed.
14
//
15
// We mean it.
16
//
17
18
#include <QtDBus/private/qtdbusglobal_p.h>
19
#include <QtCore/qloggingcategory.h>
20
#include <QtCore/qmap.h>
21
#include <QtCore/qxmlstream.h>
22
#include "
qdbusintrospection_p.h
"
23
24
#ifndef QT_NO_DBUS
25
26
QT_BEGIN_NAMESPACE
27
28
Q_DECLARE_LOGGING_CATEGORY
(dbusParser)
29
30
33
class
QDBusXmlParser
34
{
35
QString
m_service;
36
QString
m_path;
37
QSharedDataPointer<QDBusIntrospection::Object>
m_object;
38
std::unique_ptr<QDBusIntrospection::Interface> m_currentInterface;
39
QDBusIntrospection::Interfaces
m_interfaces;
40
QXmlStreamReader m_xml;
41
QDBusIntrospection::SourceLocation
m_currentLocation;
42
QDBusIntrospection::DiagnosticsReporter
*m_reporter;
43
44
public
:
45
QDBusXmlParser
(
const
QString
&service,
const
QString
&
path
,
const
QString
&xmlData,
46
QDBusIntrospection::DiagnosticsReporter
*reporter =
nullptr
);
47
48
inline
QDBusIntrospection::Interfaces
interfaces
()
const
{
return
m_interfaces; }
49
inline
QSharedDataPointer<QDBusIntrospection::Object>
object
()
const
{
return
m_object; }
50
51
private
:
52
void
readNode(
int
nodeLevel);
53
void
readInterface();
54
bool
parseSignal(
QDBusIntrospection::Signal
&signalData);
55
bool
parseMethod(
QDBusIntrospection::Method
&methodData);
56
bool
parseProperty(
QDBusIntrospection::Property
&propertyData);
57
bool
parseAnnotation(
QDBusIntrospection::Annotations
&annotations,
58
bool
interfaceAnnotation =
false
);
59
bool
parseArg(
const
QXmlStreamAttributes
&attributes,
QDBusIntrospection::Argument
&argData);
60
bool
readNextStartElement();
61
void
updateCurrentLocation();
62
};
63
64
QT_END_NAMESPACE
65
66
#endif
// QT_NO_DBUS
67
#endif
QDBusIntrospection::DiagnosticsReporter
Definition
qdbusintrospection_p.h:63
QDBusXmlParser
Definition
qdbusxmlparser_p.h:34
QDBusXmlParser::interfaces
QDBusIntrospection::Interfaces interfaces() const
Definition
qdbusxmlparser_p.h:48
QDBusXmlParser::object
QSharedDataPointer< QDBusIntrospection::Object > object() const
Definition
qdbusxmlparser_p.h:49
QMap< QString, QSharedDataPointer< Interface > >
QSharedDataPointer
\inmodule QtCore
Definition
qshareddata.h:35
QString
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition
qstring.h:127
QXmlStreamAttributes
Definition
qxmlstream.h:75
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qstandardpaths_haiku.cpp:21
QT_END_NAMESPACE
Definition
qsharedpointer.cpp:1545
qdbusintrospection_p.h
Q_DECLARE_LOGGING_CATEGORY
#define Q_DECLARE_LOGGING_CATEGORY(name)
Definition
qloggingcategory.h:106
path
GLsizei const GLchar *const * path
Definition
qopenglext.h:4283
QDBusIntrospection::Argument
\inmodule QtDBus
Definition
qdbusintrospection_p.h:72
QDBusIntrospection::Method
\inmodule QtDBus
Definition
qdbusintrospection_p.h:82
QDBusIntrospection::Property
\inmodule QtDBus
Definition
qdbusintrospection_p.h:107
QDBusIntrospection::Signal
\inmodule QtDBus
Definition
qdbusintrospection_p.h:95
QDBusIntrospection::SourceLocation
Definition
qdbusintrospection_p.h:57
qtbase
src
dbus
qdbusxmlparser_p.h
Generated by
1.9.7