OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef BASE_SYS_INFO_H_ | 5 #ifndef BASE_SYS_INFO_H_ |
6 #define BASE_SYS_INFO_H_ | 6 #define BASE_SYS_INFO_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/base_api.h" | 9 #include "base/base_api.h" |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 23 matching lines...) Expand all Loading... |
34 | 34 |
35 // Returns the name of the host operating system. | 35 // Returns the name of the host operating system. |
36 static std::string OperatingSystemName(); | 36 static std::string OperatingSystemName(); |
37 | 37 |
38 // Returns the version of the host operating system. | 38 // Returns the version of the host operating system. |
39 static std::string OperatingSystemVersion(); | 39 static std::string OperatingSystemVersion(); |
40 | 40 |
41 // Retrieves detailed numeric values for the OS version. | 41 // Retrieves detailed numeric values for the OS version. |
42 // TODO(port): Implement a Linux version of this method and enable the | 42 // TODO(port): Implement a Linux version of this method and enable the |
43 // corresponding unit test. | 43 // corresponding unit test. |
| 44 // DON'T USE THIS ON THE MAC to determine the current OS release for |
| 45 // OS version-specific feature checks and workarounds. If you must use |
| 46 // an OS version check instead of a feature check, use the base::mac::IsOS* |
| 47 // family from base/mac/mac_util.h. |
44 static void OperatingSystemVersionNumbers(int32* major_version, | 48 static void OperatingSystemVersionNumbers(int32* major_version, |
45 int32* minor_version, | 49 int32* minor_version, |
46 int32* bugfix_version); | 50 int32* bugfix_version); |
47 | 51 |
48 // Returns the CPU architecture of the system. Exact return value may differ | 52 // Returns the CPU architecture of the system. Exact return value may differ |
49 // across platforms. | 53 // across platforms. |
50 static std::string CPUArchitecture(); | 54 static std::string CPUArchitecture(); |
51 | 55 |
52 // Returns the pixel dimensions of the primary display via the | 56 // Returns the pixel dimensions of the primary display via the |
53 // width and height parameters. | 57 // width and height parameters. |
(...skipping 21 matching lines...) Expand all Loading... |
75 static void ParseLsbRelease(const std::string& lsb_release, | 79 static void ParseLsbRelease(const std::string& lsb_release, |
76 int32* major_version, | 80 int32* major_version, |
77 int32* minor_version, | 81 int32* minor_version, |
78 int32* bugfix_version); | 82 int32* bugfix_version); |
79 #endif | 83 #endif |
80 }; | 84 }; |
81 | 85 |
82 } // namespace base | 86 } // namespace base |
83 | 87 |
84 #endif // BASE_SYS_INFO_H_ | 88 #endif // BASE_SYS_INFO_H_ |
OLD | NEW |