Trait MintQuotesDatabase

Source
pub trait MintQuotesDatabase {
    type Err: Into<Error> + From<Error>;

Show 15 methods // Required methods fn add_mint_quote<'life0, 'async_trait>( &'life0 self, quote: MintMintQuote, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn get_mint_quote<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<Option<MintMintQuote>, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn update_mint_quote_state<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, state: MintQuoteState, ) -> Pin<Box<dyn Future<Output = Result<MintQuoteState, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn get_mint_quote_by_request<'life0, 'life1, 'async_trait>( &'life0 self, request: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Option<MintMintQuote>, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn get_mint_quote_by_request_lookup_id<'life0, 'life1, 'async_trait>( &'life0 self, request_lookup_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Option<MintMintQuote>, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn get_mint_quotes<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<MintMintQuote>, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn get_mint_quotes_with_state<'life0, 'async_trait>( &'life0 self, state: MintQuoteState, ) -> Pin<Box<dyn Future<Output = Result<Vec<MintMintQuote>, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn remove_mint_quote<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn add_melt_quote<'life0, 'async_trait>( &'life0 self, quote: MeltQuote, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn get_melt_quote<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<Option<MeltQuote>, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn update_melt_quote_state<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, state: MeltQuoteState, ) -> Pin<Box<dyn Future<Output = Result<MeltQuoteState, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn get_melt_quotes<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<MeltQuote>, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn remove_melt_quote<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn add_melt_request<'life0, 'async_trait>( &'life0 self, melt_request: MeltBolt11Request<Uuid>, ln_key: PaymentProcessorKey, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn get_melt_request<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<Option<(MeltBolt11Request<Uuid>, PaymentProcessorKey)>, Self::Err>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait;
}
Expand description

Mint Quote Database trait

Required Associated Types§

Source

type Err: Into<Error> + From<Error>

Mint Quotes Database Error

Required Methods§

Source

fn add_mint_quote<'life0, 'async_trait>( &'life0 self, quote: MintMintQuote, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn get_mint_quote<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<Option<MintMintQuote>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn update_mint_quote_state<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, state: MintQuoteState, ) -> Pin<Box<dyn Future<Output = Result<MintQuoteState, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Update state of MintMintQuote

Source

fn get_mint_quote_by_request<'life0, 'life1, 'async_trait>( &'life0 self, request: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Option<MintMintQuote>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Get all MintMintQuotes

Source

fn get_mint_quote_by_request_lookup_id<'life0, 'life1, 'async_trait>( &'life0 self, request_lookup_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Option<MintMintQuote>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Get all MintMintQuotes

Source

fn get_mint_quotes<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<MintMintQuote>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get Mint Quotes

Source

fn get_mint_quotes_with_state<'life0, 'async_trait>( &'life0 self, state: MintQuoteState, ) -> Pin<Box<dyn Future<Output = Result<Vec<MintMintQuote>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get Mint Quotes with state

Source

fn remove_mint_quote<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn add_melt_quote<'life0, 'async_trait>( &'life0 self, quote: MeltQuote, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn get_melt_quote<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<Option<MeltQuote>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn update_melt_quote_state<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, state: MeltQuoteState, ) -> Pin<Box<dyn Future<Output = Result<MeltQuoteState, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Update mint::MeltQuote state

Source

fn get_melt_quotes<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<MeltQuote>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get all mint::MeltQuotes

Source

fn remove_melt_quote<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn add_melt_request<'life0, 'async_trait>( &'life0 self, melt_request: MeltBolt11Request<Uuid>, ln_key: PaymentProcessorKey, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Add melt request

Source

fn get_melt_request<'life0, 'life1, 'async_trait>( &'life0 self, quote_id: &'life1 Uuid, ) -> Pin<Box<dyn Future<Output = Result<Option<(MeltBolt11Request<Uuid>, PaymentProcessorKey)>, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Get melt request

Implementors§