mirror of
https://github.com/matrix-construct/construct
synced 2024-11-27 09:12:36 +01:00
64 lines
1.3 KiB
C++
64 lines
1.3 KiB
C++
// Matrix Construct
|
|
//
|
|
// Copyright (C) Matrix Construct Developers, Authors & Contributors
|
|
// Copyright (C) 2016-2018 Jason Volk <jason@zemos.net>
|
|
//
|
|
// Permission to use, copy, modify, and/or distribute this software for any
|
|
// purpose with or without fee is hereby granted, provided that the above
|
|
// copyright notice and this permission notice is present in all copies. The
|
|
// full license for this software is available in the LICENSE file.
|
|
|
|
ircd::mapi::header
|
|
IRCD_MODULE
|
|
{
|
|
"Client Sync :Rooms Ephemeral"
|
|
};
|
|
|
|
namespace ircd::m::sync
|
|
{
|
|
static void rooms_ephemeral_events_polylog(data &);
|
|
static void rooms_ephemeral_polylog(data &);
|
|
static void rooms_ephemeral_linear(data &);
|
|
extern item rooms_ephemeral;
|
|
}
|
|
|
|
decltype(ircd::m::sync::rooms_ephemeral)
|
|
ircd::m::sync::rooms_ephemeral
|
|
{
|
|
"rooms.ephemeral",
|
|
rooms_ephemeral_polylog,
|
|
rooms_ephemeral_linear
|
|
};
|
|
|
|
void
|
|
ircd::m::sync::rooms_ephemeral_linear(data &data)
|
|
{
|
|
|
|
}
|
|
|
|
void
|
|
ircd::m::sync::rooms_ephemeral_polylog(data &data)
|
|
{
|
|
json::stack::object object
|
|
{
|
|
data.out
|
|
};
|
|
|
|
rooms_ephemeral_events_polylog(data);
|
|
}
|
|
|
|
void
|
|
ircd::m::sync::rooms_ephemeral_events_polylog(data &data)
|
|
{
|
|
json::stack::array array
|
|
{
|
|
data.out, "events"
|
|
};
|
|
|
|
m::sync::for_each("rooms.ephemeral", [&]
|
|
(item &item)
|
|
{
|
|
item.polylog(data);
|
|
return true;
|
|
});
|
|
}
|