use revolt_result::Result;
use crate::File;
mod mongodb;
mod reference;
#[async_trait]
pub trait AbstractAttachments: Sync + Send {
async fn insert_attachment(&self, attachment: &File) -> Result<()>;
async fn find_and_use_attachment(
&self,
id: &str,
tag: &str,
parent_type: &str,
parent_id: &str,
) -> Result<File>;
async fn mark_attachment_as_reported(&self, id: &str) -> Result<()>;
async fn mark_attachment_as_deleted(&self, id: &str) -> Result<()>;
async fn mark_attachments_as_deleted(&self, ids: &[String]) -> Result<()>;
}