Stroika Library 3.0d16
 
Loading...
Searching...
No Matches
Measurement.h
1/*
2 * Copyright(c) Sophist Solutions, Inc. 1990-2025. All rights reserved
3 */
4#ifndef _Stroika_Framework_SystemPerformance_Measurement_h_
5#define _Stroika_Framework_SystemPerformance_Measurement_h_ 1
6
7#include "Stroika/Frameworks/StroikaPreComp.h"
8
10#include "Stroika/Foundation/Containers/Collection.h"
13
14/*
15 * TODO:
16 * @todo Consider adding some sort of MeasurementType registry to capture meta inforamtion - descriptions
17 * etc - about measurements. Don't do yet, cuz I'm not sure how to manage it - when to add things.
18 *
19 * The challenge is how do to this modularly.
20 *
21 */
22
23namespace Stroika::Frameworks::SystemPerformance {
24
25 using namespace Stroika::Foundation;
29
30 /**
31 *
32 */
33 using MeasurementType = DataExchange::Atom<>;
34
35 /**
36 * A measurement refers to a single UNIT of related fields from an Instrument. It often contains tens or hundreds of fields.
37 * the fType field is an atom, which identifies the object type you can convert the fValue to.
38 *
39 * \note \em Thread-Safety <a href="Thread-Safety.md#C++-Standard-Thread-Safety">C++-Standard-Thread-Safety</a>
40 */
41 struct Measurement {
42 MeasurementType fType;
43 VariantValue fValue;
44
45 /**
46 * @see Characters::ToString ();
47 */
48 nonvirtual String ToString () const;
49 };
50
51}
52
53/*
54 ********************************************************************************
55 ***************************** Implementation Details ***************************
56 ********************************************************************************
57 */
58#include "Measurement.inl"
59
60#endif /*_Stroika_Framework_SystemPerformance_Measurement_h_*/
String is like std::u32string, except it is much easier to use, often much more space efficient,...
Definition String.h:201
A Collection<T> is a container to manage an un-ordered collection of items, without equality defined ...
Definition Collection.h:102
An Atom is like a String, except that its much cheaper to copy/store/compare, and the semantics of co...
Definition Atom.h:133
Simple variant-value (case variant union) object, with (variant) basic types analogous to a value in ...