parcel 0.2.2
Wrappable, wire-transferable C++23 value system with JSON serialization
Loading...
Searching...
No Matches
parcel::CellLike Concept Reference

Concept naming the static interface every cell type must expose. More...

#include <cell.h>

Concept definition

template<typename T>
concept parcel::CellLike = std::derived_from<T, ICell> && requires {
{ T::kind_id } -> std::convertible_to<std::string_view>;
{
T::from_json(std::declval<json_t const&>(), std::declval<ParcelRegistry const&>())
} -> std::convertible_to<cell_t>;
{ T::descriptor() } -> std::convertible_to<cell_type_descriptor_t>;
}
Concept naming the static interface every cell type must expose.
Definition cell.h:322

Detailed Description

Concept naming the static interface every cell type must expose.

A CellLike type derives from ICell, declares a kind_id string view, provides a from_json(j, registry) factory, and exposes a static descriptor() returning a cell_type_descriptor_t.

Template Parameters
TCandidate cell type.