ObjFW  Diff

Differences From Artifact [3ad9329aa1]:

To Artifact [6c02f851ee]:


25
26
27
28
29
30
31



32
33
34
35
36
37
38
 *
 * @brief A class for querying information about the system.
 */
@interface OFSystemInfo: OFObject
#ifdef OF_HAVE_CLASS_PROPERTIES
@property (class, readonly, nonatomic) size_t pageSize;
@property (class, readonly, nonatomic) size_t numberOfCPUs;



# ifdef OF_HAVE_FILES
@property (class, readonly, nullable, nonatomic) OFString *userDataPath;
@property (class, readonly, nullable, nonatomic) OFString *userConfigPath;
# endif
@property (class, readonly, nullable, nonatomic) OFString *CPUVendor;
# if defined(OF_X86_64) || defined(OF_X86) || defined(DOXYGEN)
@property (class, readonly, nonatomic) bool supportsMMX;







>
>
>







25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
 *
 * @brief A class for querying information about the system.
 */
@interface OFSystemInfo: OFObject
#ifdef OF_HAVE_CLASS_PROPERTIES
@property (class, readonly, nonatomic) size_t pageSize;
@property (class, readonly, nonatomic) size_t numberOfCPUs;
@property (class, readonly, nullable, nonatomic) OFString *operatingSystemName;
@property (class, readonly, nullable, nonatomic)
    OFString *operatingSystemVersion;
# ifdef OF_HAVE_FILES
@property (class, readonly, nullable, nonatomic) OFString *userDataPath;
@property (class, readonly, nullable, nonatomic) OFString *userConfigPath;
# endif
@property (class, readonly, nullable, nonatomic) OFString *CPUVendor;
# if defined(OF_X86_64) || defined(OF_X86) || defined(DOXYGEN)
@property (class, readonly, nonatomic) bool supportsMMX;
62
63
64
65
66
67
68
















69
70
71
72
73
74
75
 *
 * A CPU with multiple cores counts as multiple CPUs.
 *
 * @return The number of CPUs installed in the system
 */
+ (size_t)numberOfCPUs;

















#ifdef OF_HAVE_FILES
/*!
 * @brief Returns the path where user data for the application can be stored.
 *
 * On Unix systems, this adheres to the XDG Base Directory specification.@n
 * On Mac OS X and iOS, it uses the `NSApplicationSupportDirectory` directory.@n
 * On Windows, it uses the `APPDATA` environment variable.@n







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
 *
 * A CPU with multiple cores counts as multiple CPUs.
 *
 * @return The number of CPUs installed in the system
 */
+ (size_t)numberOfCPUs;

/**
 * @brief Returns the name of the operating system the application is running
 *	  on.
 *
 * @return The name of the operating system the application is running on
 */
+ (nullable OFString *)operatingSystemName;

/**
 * @brief Returns the version of the operating system the application is
 *	  running on.
 *
 * @return The version of the operating system the application is running on
 */
+ (nullable OFString *)operatingSystemVersion;

#ifdef OF_HAVE_FILES
/*!
 * @brief Returns the path where user data for the application can be stored.
 *
 * On Unix systems, this adheres to the XDG Base Directory specification.@n
 * On Mac OS X and iOS, it uses the `NSApplicationSupportDirectory` directory.@n
 * On Windows, it uses the `APPDATA` environment variable.@n