ruwuma/crates/ruma-macros
Benjamin Bouvier fec2152d87
events: allow deserializing an event content with a type (#1850)
This allows deserializing all the `*EventContent` types into a parent `Any{...}EventContent`, assuming we know the type of the underlying event.

Required for serializing/deserializing the content of events we'd like to send, across application restarts, as in https://github.com/matrix-org/matrix-rust-sdk/issues/3361 for the Rust SDK.

---

* events: add deserialize_with_type to all the *EventContent types

* events: add smoke test for deserializing an event content with a type

* events: add a test for deserializing a secret storage key event content

* events: add fix for correctly matching events with a type fragment

* Address review comments.
2024-06-24 10:55:12 +02:00
..
2024-05-09 12:11:41 +02:00

ruma-macros

ruma-macros provides procedural macros for easily generating types for Ruma crates.