18#ifndef itkSmapsFileParser_h
19#define itkSmapsFileParser_h
56 std::map<std::string, MemoryLoadType>
m_Tokens{};
83 friend ITKCommon_EXPORT std::istream &
100 friend ITKCommon_EXPORT std::istream &
117 friend ITKCommon_EXPORT std::istream &
190 friend ITKCommon_EXPORT std::istream &
221 friend ITKCommon_EXPORT std::istream &
235template <
typename TMapData>
247 ReadFile(
const std::string & mapFileLocation =
"") = 0;
290template <
typename TSmapsDataType>
301 ReadFile(
const std::string & mapFileLocation =
"")
override;
309template <
typename TVMMapDataType>
318 ReadFile(
const std::string & mapFileLocation =
"")
override;
322#ifndef ITK_MANUAL_INSTANTIATION
323# include "itkSmapsFileParser.hxx"
Base class for map data containers.
virtual MemoryLoadType GetTotalMemoryUsage()
virtual MemoryLoadType GetStackUsage()=0
virtual MemoryLoadType GetMemoryUsage(const char *filter, const char *token)
virtual MemoryLoadType GetHeapUsage()=0
SizeValueType MemoryLoadType
std::vector< MapRecord * > MapRecordVectorType
MapRecordVectorType m_Records
virtual ~MapFileParser()=default
typename TMapData::MemoryLoadType MemoryLoadType
std::string m_MapFilePath
MemoryLoadType GetStackUsage()
MemoryLoadType GetTotalMemoryUsage()
virtual void ReadFile(const std::string &mapFileLocation="")=0
MemoryLoadType GetHeapUsage()
MemoryLoadType GetMemoryUsage(const char *filter, const char *token="Size")
SizeValueType MemoryLoadType
std::map< std::string, MemoryLoadType > m_Tokens
Read a smaps stream and return the memory usage information. Smaps files have been added since the li...
MapData::MemoryLoadType MemoryLoadType
~SmapsData_2_6() override
friend ITKCommon_EXPORT std::istream & operator>>(std::istream &smapsStream, SmapsData_2_6 &data)
MemoryLoadType GetHeapUsage() override
MemoryLoadType GetStackUsage() override
Read a smap file (typically located in /proc/PID/smaps) and extract the memory usage information....
virtual void ReadFile(const std::string &mapFileLocation="") override
virtual ~SmapsFileParser() override=default
An entry in a smaps file.
friend ITKCommon_EXPORT std::istream & operator>>(std::istream &in, SmapsRecord &record)
friend ITKCommon_EXPORT std::istream & operator>>(std::istream &stream, VMMapData_10_2 &data)
MemoryLoadType GetHeapUsage() override
MemoryLoadType GetStackUsage() override
MapData::MemoryLoadType MemoryLoadType
~VMMapData_10_2() override
Read the output of a vmmap command and extract the memory usage information. Used for MAC OS X machin...
virtual void ReadFile(const std::string &mapFileLocation="") override
virtual ~VMMapFileParser() override=default
Contains an entry in a smaps file.
friend ITKCommon_EXPORT std::istream & operator>>(std::istream &in, VMMapRecord &record)
Contains an entry in a smaps file.
friend ITKCommon_EXPORT std::istream & operator>>(std::istream &in, VMMapSummaryRecord &record)
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
unsigned long SizeValueType