about summary refs log tree commit diff
path: root/src/database/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/database/mod.rs')
-rw-r--r--src/database/mod.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/database/mod.rs b/src/database/mod.rs
index 0993715..4390ae7 100644
--- a/src/database/mod.rs
+++ b/src/database/mod.rs
@@ -356,6 +356,10 @@ pub trait Storage: std::fmt::Debug + Clone + Send + Sync {
     /// Besides, it may even allow for nice tricks like storing the
     /// webmentions separately and rehydrating them on feed reads.
     fn add_or_update_webmention(&self, target: &str, mention_type: MentionType, mention: serde_json::Value) -> impl Future<Output = Result<()>> + Send;
+
+    /// Return a stream of all posts ever made by a certain user, in
+    /// reverse-chronological order.
+    fn all_posts<'this>(&'this self, user: &url::Url) -> impl Future<Output = Result<impl futures::Stream<Item = serde_json::Value> + Send + 'this>> + Send;
 }
 
 #[cfg(test)]