mirror of
https://github.com/matrix-construct/construct
synced 2024-09-26 18:38:52 +02:00
ircd:Ⓜ️ Add event::fetch seekless ctor w/ selection.
This commit is contained in:
parent
2b71ad8a04
commit
2f48b69102
2 changed files with 14 additions and 0 deletions
|
@ -199,6 +199,7 @@ struct ircd::m::event::fetch
|
|||
fetch(const id &, std::nothrow_t);
|
||||
fetch(const id &, const keys::selection &);
|
||||
fetch(const id &);
|
||||
fetch(const keys::selection &);
|
||||
fetch();
|
||||
|
||||
static bool event_id(const idx &, std::nothrow_t, const id::closure &);
|
||||
|
|
|
@ -1517,6 +1517,19 @@ ircd::m::event::fetch::fetch()
|
|||
{
|
||||
}
|
||||
|
||||
/// Seekless constructor.
|
||||
ircd::m::event::fetch::fetch(const keys::selection &selection)
|
||||
:row
|
||||
{
|
||||
*dbs::events, string_view{}, keys{selection}, cell
|
||||
}
|
||||
,valid
|
||||
{
|
||||
false
|
||||
}
|
||||
{
|
||||
}
|
||||
|
||||
/// Seek to event_id and populate this event from database.
|
||||
/// Throws if event not in database.
|
||||
ircd::m::event::fetch::fetch(const event::id &event_id)
|
||||
|
|
Loading…
Reference in a new issue