1 /*
2  * DQt - D bindings for the Qt Toolkit
3  *
4  * GNU Lesser General Public License Usage
5  * This file may be used under the terms of the GNU Lesser
6  * General Public License version 3 as published by the Free Software
7  * Foundation and appearing in the file LICENSE.LGPL3 included in the
8  * packaging of this file. Please review the following information to
9  * ensure the GNU Lesser General Public License version 3 requirements
10  * will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
11  */
12 module qt.core.sysinfo;
13 extern(C++):
14 
15 import qt.config;
16 import qt.core.bytearray;
17 import qt.core.string;
18 import qt.helpers;
19 
20 /+ #ifndef QSYSINFO_H +/
21 /+ #define QSYSINFO_H +/
22 
23 
24 /*
25    System information
26 */
27 
28 /// Binding for C++ class [QSysInfo](https://doc.qt.io/qt-6/qsysinfo.html).
29 extern(C++, class) struct /+ Q_CORE_EXPORT +/ QSysInfo
30 {
31 public:
32     enum Sizes {
33         WordSize = ((void*).sizeof<<3)
34     }
35 
36     enum Endian {
37         BigEndian,
38         LittleEndian
39     }
40     version(BigEndian)
41         enum ByteOrder = Endian.BigEndian;
42     else version(LittleEndian)
43         enum ByteOrder = Endian.LittleEndian;
44     else
45         static assert(0, "Undefined byte order");
46 
47     static QString buildCpuArchitecture();
48     static QString currentCpuArchitecture();
49     static QString buildAbi();
50 
51     static QString kernelType();
52     static QString kernelVersion();
53     static QString productType();
54     static QString productVersion();
55     static QString prettyProductName();
56 
57     static QString machineHostName();
58     static QByteArray machineUniqueId();
59     static QByteArray bootUniqueId();
60     mixin(CREATE_CONVENIENCE_WRAPPERS);
61 }
62 
63 /+ #endif +/ // QSYSINFO_H
64