mirror of
https://github.com/matrix-construct/construct
synced 2024-11-26 08:42:34 +01:00
ircd:Ⓜ️ Add selecting-key ctor for event from json::object.
This commit is contained in:
parent
4dc1e2d7fc
commit
fc703660f6
2 changed files with 11 additions and 8 deletions
|
@ -113,9 +113,7 @@ struct ircd::m::event
|
||||||
|
|
||||||
using super_type::tuple;
|
using super_type::tuple;
|
||||||
event(const json::object &);
|
event(const json::object &);
|
||||||
|
event(const json::object &, const keys &);
|
||||||
event() = default;
|
event() = default;
|
||||||
|
|
||||||
using super_type::operator=;
|
|
||||||
event &operator=(const json::object &);
|
|
||||||
};
|
};
|
||||||
#pragma GCC diagnostic pop
|
#pragma GCC diagnostic pop
|
||||||
|
|
|
@ -447,12 +447,17 @@ ircd::m::event::event(const json::object &source)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
ircd::m::event &
|
ircd::m::event::event(const json::object &source,
|
||||||
ircd::m::event::operator=(const json::object &source)
|
const keys &keys)
|
||||||
|
:super_type
|
||||||
|
{
|
||||||
|
source, keys
|
||||||
|
}
|
||||||
|
,source
|
||||||
|
{
|
||||||
|
source
|
||||||
|
}
|
||||||
{
|
{
|
||||||
this->super_type::operator=(source);
|
|
||||||
this->source = source;
|
|
||||||
return *this;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace ircd::m
|
namespace ircd::m
|
||||||
|
|
Loading…
Reference in a new issue