File indexing completed on 2026-09-11 09:22:01
0001
0002
0003
0004
0005 #ifndef QLIBRARYINFO_H
0006 #define QLIBRARYINFO_H
0007
0008 #include <QtCore/qstring.h>
0009 #include <QtCore/qdatetime.h>
0010 #include <QtCore/qversionnumber.h>
0011
0012 QT_BEGIN_NAMESPACE
0013
0014 class Q_CORE_EXPORT QLibraryInfo
0015 {
0016 public:
0017 static const char *build() noexcept;
0018
0019 [[nodiscard]] Q_DECL_CONST_FUNCTION static bool isDebugBuild() noexcept;
0020 [[nodiscard]] Q_DECL_CONST_FUNCTION static bool isSharedBuild() noexcept;
0021
0022 #ifndef QT_BOOTSTRAPPED
0023 Q_DECL_CONST_FUNCTION static QVersionNumber version() noexcept;
0024 #endif
0025
0026 enum LibraryPath {
0027 PrefixPath = 0,
0028 DocumentationPath,
0029 HeadersPath,
0030 LibrariesPath,
0031 LibraryExecutablesPath,
0032 BinariesPath,
0033 PluginsPath,
0034 QmlImportsPath,
0035 Qml2ImportsPath = QmlImportsPath,
0036 ArchDataPath,
0037 DataPath,
0038 TranslationsPath,
0039 ExamplesPath,
0040 TestsPath,
0041
0042
0043 SettingsPath = 100
0044 };
0045 static QString path(LibraryPath p);
0046 static QStringList paths(LibraryPath p);
0047 #if QT_DEPRECATED_SINCE(6, 0)
0048 using LibraryLocation = LibraryPath;
0049 QT_DEPRECATED_VERSION_X_6_0("Use path()")
0050 static QString location(LibraryLocation location)
0051 { return path(location); }
0052 #endif
0053 static QStringList platformPluginArguments(const QString &platformName);
0054
0055 private:
0056 QLibraryInfo();
0057 };
0058
0059 #if QT_DEPRECATED_SINCE(6, 9)
0060
0061 QT_DEPRECATED_VERSION_X_6_9("Use QLibraryInfo::isSharedBuild() instead.")
0062 Q_CORE_EXPORT Q_DECL_CONST_FUNCTION bool qSharedBuild() noexcept;
0063
0064 #endif
0065
0066 QT_END_NAMESPACE
0067
0068 #endif