summaryrefslogtreecommitdiffstats
path: root/src/qdoc/qdoc/src/qdoc/relatedclass.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/qdoc/qdoc/src/qdoc/relatedclass.h')
-rw-r--r--src/qdoc/qdoc/src/qdoc/relatedclass.h34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/qdoc/qdoc/src/qdoc/relatedclass.h b/src/qdoc/qdoc/src/qdoc/relatedclass.h
new file mode 100644
index 000000000..9ca3b849a
--- /dev/null
+++ b/src/qdoc/qdoc/src/qdoc/relatedclass.h
@@ -0,0 +1,34 @@
+// Copyright (C) 2021 The Qt Company Ltd.
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
+
+#ifndef RELATEDCLASS_H
+#define RELATEDCLASS_H
+
+#include "access.h"
+
+#include <QtCore/qstring.h>
+#include <QtCore/qstringlist.h>
+
+#include <utility>
+
+QT_BEGIN_NAMESPACE
+
+class ClassNode;
+
+struct RelatedClass
+{
+ RelatedClass() = default;
+ // constructor for resolved base class
+ RelatedClass(Access access, ClassNode *node) : m_access(access), m_node(node) {}
+ // constructor for unresolved base class
+ RelatedClass(Access access, QStringList path) : m_access(access), m_path(std::move(path)) { }
+ [[nodiscard]] bool isPrivate() const;
+
+ Access m_access {};
+ ClassNode *m_node { nullptr };
+ QStringList m_path {};
+};
+
+QT_END_NAMESPACE
+
+#endif // RELATEDCLASS_H