Example
async trait that use MaybeSend
Define “dyn newtype” (a newtype over dyn Trait
)
Implements the Display
trait for dyn newtypes whose traits implement
Display
Implement Clone
on a “dyn newtype”
Wraps a type into an enum with a default variant, this allows to add new
versions of the type in the future. Depending on context unknown versions
may be ignored or lead to errors. E.g. the client might just ignore an
unknown input version since it cannot originate from itself while the server
would reject it for not being able to validate its correctness.
This is a helper macro that generates the implementations of
DatabaseRecord
necessary for reading/writing to the
database and fetching by prefix.
MaybeSync can not be used in dyn $Trait + MaybeSend
See maybe_add_send
Define a “module plugin dyn-newtype” which is like a standard “dyn newtype”,
but with associated “module_instance_id”.
Implement Encodable
and Decodable
for a “module dyn newtype”
Define a “plugin” trait
A copy of module_lugin_static_trait_define
but for ClientConfig
, which
is a snowflake that requires : Serialize
and conditional implementation
for DynUnknown
. The macro is getting gnarly, so seems easier to
copy-paste-modify, than pile up conditional argument.
Implements the necessary traits for all associated types of a
FederationServer
module.
Implements the necessary traits for all configuration related types of a
FederationServer
module.