pub trait Database {
Show 16 methods // Required methods fn get_session<'life0, 'life1, 'async_trait>( &'life0 self, token: &'life1 str ) -> Pin<Box<dyn Future<Output = Result<Session>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn get_session_user<'life0, 'life1, 'async_trait>( &'life0 self, token: &'life1 str ) -> Pin<Box<dyn Future<Output = Result<User>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn add_session<'life0, 'life1, 'async_trait>( &'life0 self, session: &'life1 NewSession ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn get_user<'life0, 'life1, 'async_trait>( &'life0 self, username: &'life1 str ) -> Pin<Box<dyn Future<Output = Result<User>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn get_user_session<'life0, 'life1, 'async_trait>( &'life0 self, u: &'life1 User ) -> Pin<Box<dyn Future<Output = Result<Session>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn add_user<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 NewUser ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn count_history<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn count_history_cached<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn count_history_range<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, start: NaiveDateTime, end: NaiveDateTime ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn count_history_day<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, date: NaiveDate ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn count_history_month<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, date: NaiveDate ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn count_history_year<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, year: i32 ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn list_history<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, user: &'life1 User, created_after: NaiveDateTime, since: NaiveDateTime, host: &'life2 str ) -> Pin<Box<dyn Future<Output = Result<Vec<History>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait; fn add_history<'life0, 'life1, 'async_trait>( &'life0 self, history: &'life1 [NewHistory] ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn oldest_history<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User ) -> Pin<Box<dyn Future<Output = Result<History>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn calendar<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, period: TimePeriod, year: u64, month: u64 ) -> Pin<Box<dyn Future<Output = Result<HashMap<u64, TimePeriodInfo>>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait;
}

Required Methods§

source

fn get_session<'life0, 'life1, 'async_trait>( &'life0 self, token: &'life1 str ) -> Pin<Box<dyn Future<Output = Result<Session>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn get_session_user<'life0, 'life1, 'async_trait>( &'life0 self, token: &'life1 str ) -> Pin<Box<dyn Future<Output = Result<User>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn add_session<'life0, 'life1, 'async_trait>( &'life0 self, session: &'life1 NewSession ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn get_user<'life0, 'life1, 'async_trait>( &'life0 self, username: &'life1 str ) -> Pin<Box<dyn Future<Output = Result<User>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn get_user_session<'life0, 'life1, 'async_trait>( &'life0 self, u: &'life1 User ) -> Pin<Box<dyn Future<Output = Result<Session>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn add_user<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 NewUser ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn count_history<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn count_history_cached<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn count_history_range<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, start: NaiveDateTime, end: NaiveDateTime ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn count_history_day<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, date: NaiveDate ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn count_history_month<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, date: NaiveDate ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn count_history_year<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, year: i32 ) -> Pin<Box<dyn Future<Output = Result<i64>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn list_history<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, user: &'life1 User, created_after: NaiveDateTime, since: NaiveDateTime, host: &'life2 str ) -> Pin<Box<dyn Future<Output = Result<Vec<History>>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

source

fn add_history<'life0, 'life1, 'async_trait>( &'life0 self, history: &'life1 [NewHistory] ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn oldest_history<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User ) -> Pin<Box<dyn Future<Output = Result<History>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn calendar<'life0, 'life1, 'async_trait>( &'life0 self, user: &'life1 User, period: TimePeriod, year: u64, month: u64 ) -> Pin<Box<dyn Future<Output = Result<HashMap<u64, TimePeriodInfo>>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Implementors§