ParaView
vtkPVSystemInformation.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: $RCSfile$
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
25 #ifndef vtkPVSystemInformation_h
26 #define vtkPVSystemInformation_h
27 
28 #include "vtkPVClientServerCoreCoreModule.h" //needed for exports
29 #include "vtkPVInformation.h"
30 #include "vtkProcessModule.h" // needed for vtkProcessModule::ProcessTypes
31 #include "vtkStdString.h" // needed for vtkStdString
32 #include <vector> // needed for std::vector
33 
34 class VTKPVCLIENTSERVERCORECORE_EXPORT vtkPVSystemInformation : public vtkPVInformation
35 {
36 public:
37  static vtkPVSystemInformation* New();
39  void PrintSelf(ostream& os, vtkIndent indent);
40 
44  virtual void CopyFromObject(vtkObject*);
45 
49  virtual void AddInformation(vtkPVInformation*);
50 
52 
55  virtual void CopyToStream(vtkClientServerStream*);
56  virtual void CopyFromStream(const vtkClientServerStream*);
58 
60  {
62  int ProcessId; // for parallel processes, this indicates the process id.
64  vtkStdString Hostname;
65  vtkStdString OSName;
66  vtkStdString OSRelease;
67  vtkStdString OSVersion;
68  vtkStdString OSPlatform;
69  bool Is64Bits;
70  unsigned int NumberOfPhyicalCPUs;
71  unsigned int NumberOfLogicalCPUs; // per physical cpu
76  };
77 
78  // Provides access to the vector of informations.
79  const std::vector<SystemInformationType>& GetSystemInformations()
80  {
81  return this->SystemInformations;
82  }
83 
84 protected:
87 
88  std::vector<SystemInformationType> SystemInformations;
89 
90 private:
91  vtkPVSystemInformation(const vtkPVSystemInformation&) VTK_DELETE_FUNCTION;
92  void operator=(const vtkPVSystemInformation&) VTK_DELETE_FUNCTION;
93 };
94 
95 #endif
virtual void CopyFromStream(const vtkClientServerStream *)
Manage a serialized version of the information.
Information object used to collect miscellaneous system and memory information from all processes...
Store messages for the interpreter.
std::vector< SystemInformationType > SystemInformations
const std::vector< SystemInformationType > & GetSystemInformations()
void PrintSelf(ostream &os, vtkIndent indent)
virtual void AddInformation(vtkPVInformation *)
Merge another information object.
virtual void CopyToStream(vtkClientServerStream *)=0
Manage a serialized version of the information.
virtual void CopyFromObject(vtkObject *)
Transfer information about a single object into this object.
Superclass for information objects.