use std::future::Future;
use super::rpc::replication::Frame as RpcFrame;
pub use sqlite_injector::SqliteInjector;
use crate::frame::FrameNo;
pub use error::Error;
use error::Result;
mod error;
mod sqlite_injector;
pub trait Injector {
fn inject_frame(
&mut self,
frame: RpcFrame,
) -> impl Future<Output = Result<Option<FrameNo>>> + Send;
fn rollback(&mut self) -> impl Future<Output = ()> + Send;
fn flush(&mut self) -> impl Future<Output = Result<Option<FrameNo>>> + Send;
fn durable_frame_no(&mut self, frame_no: u64);
}