3#include <Infinity/api.h>
44 template<
typename T,
typename = std::enable_if_t<
45 !std::is_same_v<std::decay_t<T>,
bool> &&
46 !std::is_same_v<std::decay_t<T>,
int> &&
47 !std::is_same_v<std::decay_t<T>,
float> &&
48 !std::is_same_v<std::decay_t<T>,
double> &&
49 !std::is_same_v<std::decay_t<T>, std::nullptr_t> &&
50 !std::is_pointer_v<std::decay_t<T>> &&
71 void read(std::istream& in);
72 void write(std::ostream& out)
const;
74 size_t wrap(
const std::byte* data);
82#include <Infinity/Types/Core/PropertyValue.inl>
Base class for complex data types with memory wrapping and property support.
Definition Data.hpp:49
Definition PropertyValue.hpp:14
void read(std::istream &in)
PropertyValue(const PropertyValue &other)
size_t size_bytes() const noexcept
int as_int
Definition PropertyValue.hpp:30
PropertyValue & operator=(PropertyValue &&other) noexcept
size_t wrap(const std::byte *data)
Type
Definition PropertyValue.hpp:16
@ DOUBLE
Definition PropertyValue.hpp:21
@ NIL
Definition PropertyValue.hpp:17
@ BOOL
Definition PropertyValue.hpp:18
@ FLOAT
Definition PropertyValue.hpp:20
@ INT
Definition PropertyValue.hpp:19
bool as_bool
Definition PropertyValue.hpp:29
PropertyValue & operator=(const PropertyValue &other)
float as_float
Definition PropertyValue.hpp:31
void write(std::ostream &out) const
double as_double
Definition PropertyValue.hpp:32
PropertyValue(PropertyValue &&other) noexcept
Data * as_object
Definition PropertyValue.hpp:33