|
Jlm
|
#include <AnnotationMap.hpp>
Public Member Functions | |
| Annotation (std::string_view label, std::string value) | |
| Annotation (std::string_view label, int64_t value) | |
| Annotation (std::string_view label, uint64_t value) | |
| Annotation (std::string_view label, double value) | |
| const std::string_view & | Label () const noexcept |
| template<typename TValue > | |
| const TValue & | Value () const |
| template<typename TValue > | |
| bool | HasValueType () const noexcept |
| bool | operator== (const Annotation &other) const noexcept |
| bool | operator!= (const Annotation &other) const noexcept |
Private Types | |
| using | AnnotationValue = std::variant< std::string, int64_t, uint64_t, double > |
Private Attributes | |
| std::string_view | Label_ = {} |
| AnnotationValue | Value_ = {} |
Represents a simple key-value pair with a label and a value of type std::string, int64_t, uint64_t, or double.
Definition at line 25 of file AnnotationMap.hpp.
|
private |
Definition at line 27 of file AnnotationMap.hpp.
|
inline |
Definition at line 30 of file AnnotationMap.hpp.
|
inline |
Definition at line 35 of file AnnotationMap.hpp.
|
inline |
Definition at line 40 of file AnnotationMap.hpp.
|
inline |
Definition at line 45 of file AnnotationMap.hpp.
|
inlinenoexcept |
Checks if the type of the annotation value is equivalent to TValue.
TValue, otherwise false. Definition at line 76 of file AnnotationMap.hpp.
|
inlinenoexcept |
Gets the label of the annotation.
Definition at line 54 of file AnnotationMap.hpp.
|
inlinenoexcept |
Definition at line 88 of file AnnotationMap.hpp.
|
inlinenoexcept |
Definition at line 82 of file AnnotationMap.hpp.
|
inline |
Gets the value of the annotation. Requires the annotation value to be of type TValue.
Definition at line 64 of file AnnotationMap.hpp.
|
private |
Definition at line 94 of file AnnotationMap.hpp.
|
private |
Definition at line 95 of file AnnotationMap.hpp.