| IOLink 1.11.0

Loading...
Searching...
No Matches
VariantDataValue.h
1#pragma once
2
3#include <memory>
4
5#include <iolink/DataType.h>
6#include <iolink/IOLinkAPI.h>
7
8 namespace iolink
9{
10
18 class IOLINK_INTERFACE_API VariantDataValue
19{
20 public:
21 virtual ~VariantDataValue() = default;
22
26 virtual std::shared_ptr<VariantDataValue> clone() const = 0;
27
31 virtual DataType type() const = 0;
32
36 virtual size_t count() const = 0;
37
46 virtual const void* raw() const = 0;
47};
48
49} // end namespace iolink
iolink::DataType
Stores information about a data type.
Definition DataType.h:162
iolink::VariantDataValue
Stores metadata heterogeneous type value.
Definition VariantDataValue.h:19
iolink::VariantDataValue::type
virtual DataType type() const =0
Returns the type of the values stored.
iolink::VariantDataValue::clone
virtual std::shared_ptr< VariantDataValue > clone() const =0
Copies this value.
iolink::VariantDataValue::count
virtual size_t count() const =0
Returns the number of values of the specified type stored.
iolink::VariantDataValue::raw
virtual const void * raw() const =0
Returns a pointer to the location where all the values are stored continuously.
iolink
All IOLink symbols are enclosed in this namespace.
Definition ArrayX.h:8