Files
continuwuity/src/service/rooms/outlier/data.rs
T

10 lines
385 B
Rust
Raw Normal View History

2022-09-07 13:25:51 +02:00
use ruma::{signatures::CanonicalJsonObject, EventId};
2022-09-06 23:15:09 +02:00
2022-09-07 13:25:51 +02:00
use crate::{PduEvent, Result};
2022-09-06 23:15:09 +02:00
2022-10-05 15:33:57 +02:00
pub trait Data: Send + Sync {
fn get_outlier_pdu_json(&self, event_id: &EventId) -> Result<Option<CanonicalJsonObject>>;
fn get_outlier_pdu(&self, event_id: &EventId) -> Result<Option<PduEvent>>;
fn add_pdu_outlier(&self, event_id: &EventId, pdu: &CanonicalJsonObject) -> Result<()>;
}