summaryrefslogtreecommitdiffstats
path: root/SystemInformation.hxx.in
diff options
context:
space:
mode:
authorKWSys Upstream <kwrobot@kitware.com>2016-11-09 14:12:29 (GMT)
committerBrad King <brad.king@kitware.com>2016-11-09 14:22:56 (GMT)
commit773b36e5d4af3ac040625e0ea16bcfd30fcdeb6d (patch)
treebd409d3f09f6714981a444e896e1bc08e22ee184 /SystemInformation.hxx.in
parent53862f04a0002894c0ef5aeb23d52495e5abe60d (diff)
downloadCMake-773b36e5d4af3ac040625e0ea16bcfd30fcdeb6d.zip
CMake-773b36e5d4af3ac040625e0ea16bcfd30fcdeb6d.tar.gz
CMake-773b36e5d4af3ac040625e0ea16bcfd30fcdeb6d.tar.bz2
KWSys 2016-11-09 (18c65411)
Code extracted from: http://public.kitware.com/KWSys.git at commit 18c654114de3aa65429542f95308720bc68f9231 (master). Upstream Shortlog ----------------- Brad King (14): 37306a1c FStream: Quiet unused argument warning 15e90a3c Sort includes to stabilize include order w.r.t. clang-format 26509227 Copyright.txt: Add notice of copyright by contributors fc42d3f2 Add temporary script to filter license notices c41c1bc4 Simplify KWSys per-source license notices 1d4c0b4a Remove temporary script that filtered license notices a4f5ef79 SystemInformation: Remove stray comment 8649a886 kwsysPrivate: Protect KWSYS_HEADER macro from clang-format 89b98af5 Configure clang-format for KWSys source tree 547dacad Add a script to run clang-format on the entire source tree aa94be0c CONTRIBUTING: Add a section on coding style 6604c4b6 Empty commit at end of history preceding clang-format style transition 2b3e2b1c Tell Git to not export 'clang-format' infrastructure 18c65411 FStream: Include Configure.hxx before other headers Kitware Robot (1): 6c973b46 Revise C++ coding style using clang-format
Diffstat (limited to 'SystemInformation.hxx.in')
-rw-r--r--SystemInformation.hxx.in61
1 files changed, 24 insertions, 37 deletions
diff --git a/SystemInformation.hxx.in b/SystemInformation.hxx.in
index 7c45388..0fc1067 100644
--- a/SystemInformation.hxx.in
+++ b/SystemInformation.hxx.in
@@ -1,23 +1,14 @@
-/*============================================================================
- KWSys - Kitware System Library
- Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
-
- Distributed under the OSI-approved BSD License (the "License");
- see accompanying file Copyright.txt for details.
-
- This software is distributed WITHOUT ANY WARRANTY; without even the
- implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
- See the License for more information.
-============================================================================*/
+/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
+ file Copyright.txt or https://cmake.org/licensing#kwsys for details. */
#ifndef @KWSYS_NAMESPACE@_SystemInformation_h
#define @KWSYS_NAMESPACE@_SystemInformation_h
#include <@KWSYS_NAMESPACE@/Configure.hxx>
+
#include <stddef.h> /* size_t */
#include <string>
-namespace @KWSYS_NAMESPACE@
-{
+namespace @KWSYS_NAMESPACE@ {
// forward declare the implementation class
class SystemInformationImplementation;
@@ -29,24 +20,24 @@ class @KWSYS_NAMESPACE@_EXPORT SystemInformation
#elif @KWSYS_USE___INT64@
typedef __int64 LongLong;
#else
-# error "No Long Long"
+#error "No Long Long"
#endif
friend class SystemInformationImplementation;
SystemInformationImplementation* Implementation;
-public:
- SystemInformation ();
- ~SystemInformation ();
+public:
+ SystemInformation();
+ ~SystemInformation();
- const char * GetVendorString();
- const char * GetVendorID();
+ const char* GetVendorString();
+ const char* GetVendorID();
std::string GetTypeID();
std::string GetFamilyID();
std::string GetModelID();
std::string GetModelName();
std::string GetSteppingCode();
- const char * GetExtendedProcessorName();
- const char * GetProcessorSerialNumber();
+ const char* GetExtendedProcessorName();
+ const char* GetProcessorSerialNumber();
int GetProcessorCacheSize();
unsigned int GetLogicalProcessorsPerPhysical();
float GetProcessorClockFrequency();
@@ -58,13 +49,13 @@ public:
// on this system.
std::string GetCPUDescription();
- const char * GetHostname();
+ const char* GetHostname();
std::string GetFullyQualifiedDomainName();
- const char * GetOSName();
- const char * GetOSRelease();
- const char * GetOSVersion();
- const char * GetOSPlatform();
+ const char* GetOSName();
+ const char* GetOSRelease();
+ const char* GetOSVersion();
+ const char* GetOSPlatform();
int GetOSIsWindows();
int GetOSIsLinux();
@@ -93,9 +84,8 @@ public:
// returns an informative general description if the installed and
// available ram on this system. See the GetHostMmeoryTotal, and
// Get{Host,Proc}MemoryAvailable methods for more information.
- std::string GetMemoryDescription(
- const char *hostLimitEnvVarName=NULL,
- const char *procLimitEnvVarName=NULL);
+ std::string GetMemoryDescription(const char* hostLimitEnvVarName = NULL,
+ const char* procLimitEnvVarName = NULL);
// Retrieve amount of physical memory installed on the system in KiB
// units.
@@ -107,7 +97,7 @@ public:
// parallel. The amount of memory reported may differ from the host
// total if a host wide resource limit is applied. Such reource limits
// are reported to us via an applicaiton specified environment variable.
- LongLong GetHostMemoryAvailable(const char *hostLimitEnvVarName=NULL);
+ LongLong GetHostMemoryAvailable(const char* hostLimitEnvVarName = NULL);
// Get total system RAM in units of KiB available to this process.
// This may differ from the host available if a per-process resource
@@ -115,9 +105,8 @@ public:
// system via rlimit API. Resource limits that are not imposed via
// rlimit API may be reported to us via an application specified
// environment variable.
- LongLong GetProcMemoryAvailable(
- const char *hostLimitEnvVarName=NULL,
- const char *procLimitEnvVarName=NULL);
+ LongLong GetProcMemoryAvailable(const char* hostLimitEnvVarName = NULL,
+ const char* procLimitEnvVarName = NULL);
// Get the system RAM used by all processes on the host, in units of KiB.
LongLong GetHostMemoryUsed();
@@ -132,14 +121,12 @@ public:
// enable/disable stack trace signal handler. In order to
// produce an informative stack trace the application should
// be dynamically linked and compiled with debug symbols.
- static
- void SetStackTraceOnError(int enable);
+ static void SetStackTraceOnError(int enable);
// format and return the current program stack in a string. In
// order to produce an informative stack trace the application
// should be dynamically linked and compiled with debug symbols.
- static
- std::string GetProgramStack(int firstFrame, int wholePath);
+ static std::string GetProgramStack(int firstFrame, int wholePath);
/** Run the different checks */
void RunCPUCheck();