Remoting
Core
vtkPVSystemInformation.h
Go to the documentation of this file.
1
// SPDX-FileCopyrightText: Copyright (c) Kitware Inc.
2
// SPDX-License-Identifier: BSD-3-Clause
13
#ifndef vtkPVSystemInformation_h
14
#define vtkPVSystemInformation_h
15
16
#include "
vtkPVInformation.h
"
17
#include "
vtkProcessModule.h
"
// needed for vtkProcessModule::ProcessTypes
18
#include "
vtkRemotingCoreModule.h
"
//needed for exports
19
#include <vector>
// needed for std::vector
20
21
class
VTKREMOTINGCORE_EXPORT
vtkPVSystemInformation
:
public
vtkPVInformation
22
{
23
public
:
24
static
vtkPVSystemInformation
*
New
();
25
vtkTypeMacro(
vtkPVSystemInformation
,
vtkPVInformation
);
26
void
PrintSelf
(ostream& os,
vtkIndent
indent)
override
;
27
31
void
CopyFromObject
(
vtkObject
*)
override
;
32
36
void
AddInformation
(
vtkPVInformation
*)
override
;
37
39
42
void
CopyToStream
(
vtkClientServerStream
*)
override
;
43
void
CopyFromStream
(
const
vtkClientServerStream
*)
override
;
45
46
struct
SystemInformationType
47
{
48
vtkProcessModule::ProcessTypes
ProcessType
;
49
int
ProcessId
;
// for parallel processes, this indicates the process id.
50
int
NumberOfProcesses
;
51
std::string
Hostname
;
52
std::string
OSName
;
53
std::string
OSRelease
;
54
std::string
OSVersion
;
55
std::string
OSPlatform
;
56
bool
Is64Bits
;
57
unsigned
int
NumberOfPhyicalCPUs
;
58
unsigned
int
NumberOfLogicalCPUs
;
// per physical cpu
59
size_t
TotalPhysicalMemory
;
60
size_t
AvailablePhysicalMemory
;
61
size_t
TotalVirtualMemory
;
62
size_t
AvailableVirtualMemory
;
63
};
64
65
// Provides access to the vector of information.
66
const
std::vector<SystemInformationType>&
GetSystemInformations
()
67
{
68
return
this->SystemInformations;
69
}
70
71
protected
:
72
vtkPVSystemInformation
();
73
~
vtkPVSystemInformation
()
override
;
74
75
std::vector<SystemInformationType>
SystemInformations
;
76
77
private
:
78
vtkPVSystemInformation
(
const
vtkPVSystemInformation
&) =
delete
;
79
void
operator=(
const
vtkPVSystemInformation
&) =
delete
;
80
};
81
82
#endif
vtkPVSystemInformation::SystemInformationType::OSName
std::string OSName
Definition:
vtkPVSystemInformation.h:52
vtkPVInformation::CopyFromStream
virtual void CopyFromStream(const vtkClientServerStream *)
Manage a serialized version of the information.
vtkObject
vtkPVSystemInformation
Information object used to collect miscellaneous system and memory information from all processes...
Definition:
vtkPVSystemInformation.h:21
vtkRemotingCoreModule.h
vtkPVInformation::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
vtkPVSystemInformation::SystemInformationType::TotalPhysicalMemory
size_t TotalPhysicalMemory
Definition:
vtkPVSystemInformation.h:59
vtkPVSystemInformation::SystemInformationType::TotalVirtualMemory
size_t TotalVirtualMemory
Definition:
vtkPVSystemInformation.h:61
vtkPVSystemInformation::SystemInformationType::ProcessType
vtkProcessModule::ProcessTypes ProcessType
Definition:
vtkPVSystemInformation.h:48
vtkPVSystemInformation::SystemInformationType::NumberOfPhyicalCPUs
unsigned int NumberOfPhyicalCPUs
Definition:
vtkPVSystemInformation.h:57
vtkPVSystemInformation::SystemInformationType::AvailablePhysicalMemory
size_t AvailablePhysicalMemory
Definition:
vtkPVSystemInformation.h:60
vtkClientServerStream
Store messages for the interpreter.
Definition:
vtkClientServerStream.h:23
vtkPVSystemInformation::SystemInformationType::OSPlatform
std::string OSPlatform
Definition:
vtkPVSystemInformation.h:55
vtkPVSystemInformation::SystemInformationType::NumberOfLogicalCPUs
unsigned int NumberOfLogicalCPUs
Definition:
vtkPVSystemInformation.h:58
vtkIndent
vtkPVSystemInformation::SystemInformationType::ProcessId
int ProcessId
Definition:
vtkPVSystemInformation.h:49
vtkPVSystemInformation::SystemInformationType::Is64Bits
bool Is64Bits
Definition:
vtkPVSystemInformation.h:56
vtkPVSystemInformation::SystemInformations
std::vector< SystemInformationType > SystemInformations
Definition:
vtkPVSystemInformation.h:75
vtkPVSystemInformation::SystemInformationType::NumberOfProcesses
int NumberOfProcesses
Definition:
vtkPVSystemInformation.h:50
vtkPVSystemInformation::GetSystemInformations
const std::vector< SystemInformationType > & GetSystemInformations()
Definition:
vtkPVSystemInformation.h:66
vtkPVSystemInformation::SystemInformationType::OSVersion
std::string OSVersion
Definition:
vtkPVSystemInformation.h:54
VTKREMOTINGCORE_EXPORT
#define VTKREMOTINGCORE_EXPORT
Definition:
vtkRemotingCoreModule.h:15
vtkProcessModule.h
vtkProcessModule::ProcessTypes
ProcessTypes
Definition:
vtkProcessModule.h:36
vtkPVInformation::AddInformation
virtual void AddInformation(vtkPVInformation *)
Merge another information object.
vtkPVInformation::CopyToStream
virtual void CopyToStream(vtkClientServerStream *)=0
Manage a serialized version of the information.
vtkPVInformation.h
vtkPVSystemInformation::SystemInformationType
Definition:
vtkPVSystemInformation.h:46
vtkPVInformation::CopyFromObject
virtual void CopyFromObject(vtkObject *)
Transfer information about a single object into this object.
vtkPVSystemInformation::SystemInformationType::AvailableVirtualMemory
size_t AvailableVirtualMemory
Definition:
vtkPVSystemInformation.h:62
vtkObject::New
static vtkObject * New()
vtkPVSystemInformation::SystemInformationType::OSRelease
std::string OSRelease
Definition:
vtkPVSystemInformation.h:53
vtkPVInformation
Superclass for information objects.
Definition:
vtkPVInformation.h:19
vtkPVSystemInformation::SystemInformationType::Hostname
std::string Hostname
Definition:
vtkPVSystemInformation.h:51
Generated by
1.8.13 on Tue Oct 1 2024