Trait luna_orm::prelude::CommandExecutor
source · pub trait CommandExecutor: SqlExecutor {
type G: SqlGenerator + Sync;
Show 17 methods
// Required method
fn get_generator(&self) -> &Self::G;
// Provided methods
fn select<'life0, 'life1, 'life2, 'async_trait, SE>(
&'life0 mut self,
primary: &'life1 dyn Primary,
selection: &'life2 dyn Selection
) -> Pin<Box<dyn Future<Output = LunaOrmResult<Option<SE>>> + Send + 'async_trait>>
where SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
fn create<'a, 'life0, 'async_trait>(
&'life0 mut self,
entity: &'a dyn Entity
) -> Pin<Box<dyn Future<Output = LunaOrmResult<&'a dyn Entity>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'a: 'async_trait,
'life0: 'async_trait { ... }
fn insert<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity: &'life1 dyn Entity
) -> Pin<Box<dyn Future<Output = LunaOrmResult<bool>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn upsert<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity: &'life1 dyn Entity
) -> Pin<Box<dyn Future<Output = LunaOrmResult<bool>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn update<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
mutation: &'life1 dyn Mutation,
primary: &'life2 dyn Primary
) -> Pin<Box<dyn Future<Output = LunaOrmResult<bool>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
fn delete<'life0, 'life1, 'async_trait>(
&'life0 mut self,
primary: &'life1 dyn Primary
) -> Pin<Box<dyn Future<Output = LunaOrmResult<bool>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn search<'life0, 'life1, 'life2, 'life3, 'async_trait, SE>(
&'life0 mut self,
location: &'life1 dyn Location,
order_by: Option<&'life2 dyn OrderBy>,
selection: &'life3 dyn Selection
) -> Pin<Box<dyn Future<Output = LunaOrmResult<Vec<SE>>> + Send + 'async_trait>>
where SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait { ... }
fn count<'life0, 'life1, 'async_trait>(
&'life0 mut self,
location: &'life1 dyn Location
) -> Pin<Box<dyn Future<Output = LunaOrmResult<usize>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn search_paged<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait, SE>(
&'life0 mut self,
location: &'life1 dyn Location,
order_by: Option<&'life2 dyn OrderBy>,
selection: &'life3 dyn Selection,
page: &'life4 Pagination
) -> Pin<Box<dyn Future<Output = LunaOrmResult<PagedList<SE>>> + Send + 'async_trait>>
where SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait { ... }
fn search_joined<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait, SE>(
&'life0 mut self,
joined_conds: JoinedConditions,
locations: Vec<&'life1 dyn Location>,
order_by: Option<&'life2 dyn OrderBy>,
selections: Vec<&'life3 dyn Selection>,
page: &'life4 Pagination
) -> Pin<Box<dyn Future<Output = String> + Send + 'async_trait>>
where SE: 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait { ... }
fn purify<'life0, 'life1, 'async_trait>(
&'life0 mut self,
location: &'life1 dyn Location
) -> Pin<Box<dyn Future<Output = LunaOrmResult<usize>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn change<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
mutation: &'life1 dyn Mutation,
location: &'life2 dyn Location
) -> Pin<Box<dyn Future<Output = LunaOrmResult<usize>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
fn execute_by_template<'life0, 'life1, 'async_trait>(
&'life0 mut self,
template: &'life1 dyn TemplateRecord
) -> Pin<Box<dyn Future<Output = LunaOrmResult<usize>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn select_by_template<'life0, 'life1, 'async_trait, SE>(
&'life0 mut self,
template: &'life1 dyn TemplateRecord
) -> Pin<Box<dyn Future<Output = LunaOrmResult<Option<SE>>> + Send + 'async_trait>>
where SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn search_by_template<'life0, 'life1, 'async_trait, SE>(
&'life0 mut self,
template: &'life1 dyn TemplateRecord
) -> Pin<Box<dyn Future<Output = LunaOrmResult<Vec<SE>>> + Send + 'async_trait>>
where SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
fn search_paged_by_template<'life0, 'life1, 'life2, 'async_trait, SE>(
&'life0 mut self,
template: &'life1 dyn TemplateRecord,
page: &'life2 Pagination
) -> Pin<Box<dyn Future<Output = LunaOrmResult<PagedList<SE>>> + Send + 'async_trait>>
where SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
}Required Associated Types§
type G: SqlGenerator + Sync
Required Methods§
fn get_generator(&self) -> &Self::G
Provided Methods§
fn select<'life0, 'life1, 'life2, 'async_trait, SE>(
&'life0 mut self,
primary: &'life1 dyn Primary,
selection: &'life2 dyn Selection
) -> Pin<Box<dyn Future<Output = LunaOrmResult<Option<SE>>> + Send + 'async_trait>>where
SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn create<'a, 'life0, 'async_trait>(
&'life0 mut self,
entity: &'a dyn Entity
) -> Pin<Box<dyn Future<Output = LunaOrmResult<&'a dyn Entity>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
fn insert<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity: &'life1 dyn Entity
) -> Pin<Box<dyn Future<Output = LunaOrmResult<bool>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn upsert<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity: &'life1 dyn Entity
) -> Pin<Box<dyn Future<Output = LunaOrmResult<bool>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn update<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
mutation: &'life1 dyn Mutation,
primary: &'life2 dyn Primary
) -> Pin<Box<dyn Future<Output = LunaOrmResult<bool>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn delete<'life0, 'life1, 'async_trait>(
&'life0 mut self,
primary: &'life1 dyn Primary
) -> Pin<Box<dyn Future<Output = LunaOrmResult<bool>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn search<'life0, 'life1, 'life2, 'life3, 'async_trait, SE>(
&'life0 mut self,
location: &'life1 dyn Location,
order_by: Option<&'life2 dyn OrderBy>,
selection: &'life3 dyn Selection
) -> Pin<Box<dyn Future<Output = LunaOrmResult<Vec<SE>>> + Send + 'async_trait>>where
SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn count<'life0, 'life1, 'async_trait>(
&'life0 mut self,
location: &'life1 dyn Location
) -> Pin<Box<dyn Future<Output = LunaOrmResult<usize>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn search_paged<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait, SE>(
&'life0 mut self,
location: &'life1 dyn Location,
order_by: Option<&'life2 dyn OrderBy>,
selection: &'life3 dyn Selection,
page: &'life4 Pagination
) -> Pin<Box<dyn Future<Output = LunaOrmResult<PagedList<SE>>> + Send + 'async_trait>>where
SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn search_joined<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait, SE>(
&'life0 mut self,
joined_conds: JoinedConditions,
locations: Vec<&'life1 dyn Location>,
order_by: Option<&'life2 dyn OrderBy>,
selections: Vec<&'life3 dyn Selection>,
page: &'life4 Pagination
) -> Pin<Box<dyn Future<Output = String> + Send + 'async_trait>>where
SE: 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn purify<'life0, 'life1, 'async_trait>(
&'life0 mut self,
location: &'life1 dyn Location
) -> Pin<Box<dyn Future<Output = LunaOrmResult<usize>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn change<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
mutation: &'life1 dyn Mutation,
location: &'life2 dyn Location
) -> Pin<Box<dyn Future<Output = LunaOrmResult<usize>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn execute_by_template<'life0, 'life1, 'async_trait>(
&'life0 mut self,
template: &'life1 dyn TemplateRecord
) -> Pin<Box<dyn Future<Output = LunaOrmResult<usize>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn select_by_template<'life0, 'life1, 'async_trait, SE>(
&'life0 mut self,
template: &'life1 dyn TemplateRecord
) -> Pin<Box<dyn Future<Output = LunaOrmResult<Option<SE>>> + Send + 'async_trait>>where
SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn search_by_template<'life0, 'life1, 'async_trait, SE>(
&'life0 mut self,
template: &'life1 dyn TemplateRecord
) -> Pin<Box<dyn Future<Output = LunaOrmResult<Vec<SE>>> + Send + 'async_trait>>where
SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn search_paged_by_template<'life0, 'life1, 'life2, 'async_trait, SE>(
&'life0 mut self,
template: &'life1 dyn TemplateRecord,
page: &'life2 Pagination
) -> Pin<Box<dyn Future<Output = LunaOrmResult<PagedList<SE>>> + Send + 'async_trait>>where
SE: SelectedEntity + Send + Unpin + 'async_trait,
Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Object Safety§
This trait is not object safe.