Appearance
class flake::Property
A single typed, tagged property value. More...
#include <platform/flake/FlakeTypes.h>
Public Functions
| Name | |
|---|---|
| Property(Property && ) =default | |
| Property & | operator=(Property && ) =default |
| uint32_t | tag() const |
| bool | isMeta() const |
| void | setNull() |
| void | setError(tt_int8_t err) |
| PropValue | data() const |
| template <typename T > void | setData(const T & data) |
| template <typename T > std::optional< T > | value() const |
| Property(const uint32_t _tag) | |
| Property() | |
| Property(const Property & v) | |
| void | makeReadOnly() const |
| ~Property() | |
| void | releaseOwned() Free the array or blob payload this property owns and forget it. |
| void | setDeallocSelf() |
| bool | isDirty() const |
| void | markDirty() |
| void | markClean() |
| Property & | operator=(const Property & other) |
| void | copyFrom(const Property & other) |
| bool | serializeTo(uint8_t * buf, uint16_t & offset, uint16_t bufSize, uint16_t * consumedBytes =nullptr) const |
| bool | deserializeFrom(const uint8_t * buf, uint16_t & offset, uint16_t bufSize, uint16_t * consumedBytes =nullptr) |
| bool | isErrorValue() const |
| uint16_t | getSerializedSize() const |
| char * | toString() const |
Friends
| Name | |
|---|---|
| bool | operator==(const Property & lhs, const Property & rhs) |
| bool | operator!=(const Property & lhs, const Property & rhs) |
Detailed Description
cpp
class flake::Property;A single typed, tagged property value.
A Property combines a 32-bit tag (encoding property ID, type code, and attribute flags) with an optional variant value. Properties are the atomic unit of the Flake data model: every object state change, every RPC parameter, and every bus notification is expressed as one or more Properties inside a PropArray.
Properties support binary serialization/deserialization for on-wire transport, deep-copy semantics for binary/array payloads, and null/error sentinel states.
Public Functions Documentation
function Property
cpp
Property(
Property &&
) =defaultfunction operator=
cpp
Property & operator=(
Property &&
) =defaultfunction tag
cpp
inline uint32_t tag() constfunction isMeta
cpp
inline bool isMeta() constfunction setNull
cpp
inline void setNull()function setError
cpp
inline void setError(
tt_int8_t err
)function data
cpp
inline PropValue data() constfunction setData
cpp
template <typename T >
inline void setData(
const T & data
)function value
cpp
template <typename T >
inline std::optional< T > value() constfunction Property
cpp
inline explicit Property(
const uint32_t _tag
)function Property
cpp
inline Property()function Property
cpp
inline Property(
const Property & v
)function makeReadOnly
cpp
inline void makeReadOnly() constfunction ~Property
cpp
inline ~Property()function releaseOwned
cpp
inline void releaseOwned()Free the array or blob payload this property owns and forget it.
function setDeallocSelf
cpp
inline void setDeallocSelf()function isDirty
cpp
inline bool isDirty() constStatus helpers for the merged property store. isDirty true means the value has been set locally but not yet acknowledged by the owning peer; cleared once a sync CONF lands or a changed indication brings the same value back.
function markDirty
cpp
inline void markDirty()function markClean
cpp
inline void markClean()function operator=
cpp
inline Property & operator=(
const Property & other
)function copyFrom
cpp
inline void copyFrom(
const Property & other
)< Memory allocation failed.
< Memory allocation failed.
function serializeTo
cpp
inline bool serializeTo(
uint8_t * buf,
uint16_t & offset,
uint16_t bufSize,
uint16_t * consumedBytes =nullptr
) constfunction deserializeFrom
cpp
inline bool deserializeFrom(
const uint8_t * buf,
uint16_t & offset,
uint16_t bufSize,
uint16_t * consumedBytes =nullptr
)function isErrorValue
cpp
inline bool isErrorValue() constfunction getSerializedSize
cpp
inline uint16_t getSerializedSize() constfunction toString
cpp
inline char * toString() constFriends
friend operator==
cpp
friend bool operator==(
const Property & lhs,
const Property & rhs
);friend operator!=
cpp
friend bool operator!=(
const Property & lhs,
const Property & rhs
);