ArmNN
 24.02
Measurement Struct Reference

#include <Instrument.hpp>

Public Types

enum  Unit { TIME_NS, TIME_US, TIME_MS }
 

Public Member Functions

 Measurement (const std::string &name, double value, Unit unit)
 
 Measurement (const Measurement &)=default
 
 ~Measurement ()=default
 

Static Public Member Functions

static const char * ToString (Unit unit)
 

Public Attributes

std::string m_Name
 
double m_Value
 
Unit m_Unit
 

Detailed Description

Definition at line 14 of file Instrument.hpp.

Member Enumeration Documentation

◆ Unit

enum Unit
Enumerator
TIME_NS 
TIME_US 
TIME_MS 

Definition at line 16 of file Instrument.hpp.

17  {
18  TIME_NS,
19  TIME_US,
20  TIME_MS,
21  };

Constructor & Destructor Documentation

◆ Measurement() [1/2]

Measurement ( const std::string &  name,
double  value,
Unit  unit 
)
inline

Definition at line 34 of file Instrument.hpp.

35  : m_Name(name)
36  , m_Value(value)
37  , m_Unit(unit)
38  {}

◆ Measurement() [2/2]

Measurement ( const Measurement )
default

◆ ~Measurement()

~Measurement ( )
default

Member Function Documentation

◆ ToString()

static const char* ToString ( Unit  unit)
inlinestatic

Definition at line 23 of file Instrument.hpp.

24  {
25  switch (unit)
26  {
27  case TIME_NS: return "ns";
28  case TIME_US: return "us";
29  case TIME_MS: return "ms";
30  default: return "";
31  }
32  }

References Measurement::TIME_MS, Measurement::TIME_NS, and Measurement::TIME_US.

Referenced by JsonPrinter::PrintUnit().

Member Data Documentation

◆ m_Name

std::string m_Name

Definition at line 42 of file Instrument.hpp.

◆ m_Unit

Unit m_Unit

Definition at line 44 of file Instrument.hpp.

◆ m_Value


The documentation for this struct was generated from the following file:
armnn::Measurement::m_Value
double m_Value
Definition: Instrument.hpp:43
armnn::Measurement::TIME_MS
@ TIME_MS
Definition: Instrument.hpp:20
armnn::Measurement::m_Unit
Unit m_Unit
Definition: Instrument.hpp:44
armnn::Measurement::TIME_NS
@ TIME_NS
Definition: Instrument.hpp:18
armnn::Measurement::TIME_US
@ TIME_US
Definition: Instrument.hpp:19
armnn::Measurement::m_Name
std::string m_Name
Definition: Instrument.hpp:42