#![recursion_limit = "128"]
use futures::Future;
mod api;
pub mod engines;
pub mod stores;
pub use self::api::create_settlement_engine_filter;
use bytes::Bytes;
use http::StatusCode;
use interledger_http::error::ApiError;
use interledger_settlement::Quantity;
pub type ApiResponse = (StatusCode, Bytes);
pub trait SettlementEngine {
fn send_money(
&self,
account_id: String,
money: Quantity,
) -> Box<dyn Future<Item = ApiResponse, Error = ApiError> + Send>;
fn receive_message(
&self,
account_id: String,
message: Vec<u8>,
) -> Box<dyn Future<Item = ApiResponse, Error = ApiError> + Send>;
fn create_account(
&self,
account_id: String,
) -> Box<dyn Future<Item = ApiResponse, Error = ApiError> + Send>;
}