5#ifndef MP_PROXY_TYPE_MAP_H
6#define MP_PROXY_TYPE_MAP_H
15template <
typename KeyLocalType,
typename ValueLocalType,
typename Compare,
typename Allocator,
typename Value,
typename Output>
35template <
class Map,
class Tuple1,
class Tuple2>
38 const std::piecewise_construct_t&,
42 if constexpr (std::tuple_size_v<std::remove_reference_t<Tuple1>> == 0) {
44 return m.emplace(std::piecewise_construct,
45 std::forward_as_tuple(
typename Map::key_type{}),
46 std::forward<Tuple2>(
t2));
48 return m.emplace(std::piecewise_construct,
49 std::forward<Tuple1>(
t1),
50 std::forward<Tuple2>(
t2));
54template <
typename KeyLocalType,
typename ValueLocalType,
typename Compare,
typename Allocator,
typename Input,
typename ReadDest>
63 [&](
auto& value,
size_t) { value.clear(); },
64 [&](
auto& value,
auto&&...
args) ->
auto& {
Functions to serialize / deserialize common bitcoin types.
void BuildList(TypeList< LocalType >, InvokeContext &invoke_context, Output &&output, Value &&value)
auto EmplacePiecewiseSafe(Map &m, const std::piecewise_construct_t &, Tuple1 &&t1, Tuple2 &&t2)
decltype(auto) CustomReadField(TypeList< LocalType >, Priority< 1 >, InvokeContext &invoke_context, Input &&input, ReadDest &&read_dest)
Overload multiprocess library's CustomReadField hook to allow any object with an Unserialize method t...
decltype(auto) ReadList(TypeList< LocalType >, InvokeContext &invoke_context, Input &&input, ReadDest &&read_dest, InitFn &&init, EmplaceFn &&emplace)
void CustomBuildField(TypeList< LocalType >, Priority< 1 >, InvokeContext &invoke_context, Value &&value, Output &&output)
Overload multiprocess library's CustomBuildField hook to allow any serializable object to be stored i...
Function parameter type for prioritizing overloaded function calls that would otherwise be ambiguous.
Type holding a list of types.
constexpr auto Ticks(Dur2 d)
Helper to count the seconds of a duration/time_point.