Trait sqlx_core::executor::Execute [−][src]
pub trait Execute<'q, DB: Database>: Send + Sized { fn sql(&self) -> &'q str; fn statement(&self) -> Option<&<DB as HasStatement<'q>>::Statement>; fn take_arguments(&mut self) -> Option<<DB as HasArguments<'q>>::Arguments>; fn persistent(&self) -> bool; }
Expand description
Required methods
fn sql(&self) -> &'q str[src]
fn sql(&self) -> &'q str[src]Gets the SQL that will be executed.
fn statement(&self) -> Option<&<DB as HasStatement<'q>>::Statement>[src]
fn statement(&self) -> Option<&<DB as HasStatement<'q>>::Statement>[src]Gets the previously cached statement, if available.
fn take_arguments(&mut self) -> Option<<DB as HasArguments<'q>>::Arguments>[src]
fn take_arguments(&mut self) -> Option<<DB as HasArguments<'q>>::Arguments>[src]Returns the arguments to be bound against the query string.
Returning None for Arguments indicates to use a “simple” query protocol and to not
prepare the query. Returning Some(Default::default()) is an empty arguments object that
will be prepared (and cached) before execution.
fn persistent(&self) -> bool[src]
fn persistent(&self) -> bool[src]Returns true if the statement should be cached.
Implementations on Foreign Types
impl<'q, DB: Database> Execute<'q, DB> for &'q str[src]
impl<'q, DB: Database> Execute<'q, DB> for &'q str[src]fn sql(&self) -> &'q str[src]
fn statement(&self) -> Option<&<DB as HasStatement<'q>>::Statement>[src]
fn take_arguments(&mut self) -> Option<<DB as HasArguments<'q>>::Arguments>[src]
fn persistent(&self) -> bool[src]
impl<'q, DB: Database> Execute<'q, DB> for (&'q str, Option<<DB as HasArguments<'q>>::Arguments>)[src]
impl<'q, DB: Database> Execute<'q, DB> for (&'q str, Option<<DB as HasArguments<'q>>::Arguments>)[src]fn sql(&self) -> &'q str[src]
fn statement(&self) -> Option<&<DB as HasStatement<'q>>::Statement>[src]
fn take_arguments(&mut self) -> Option<<DB as HasArguments<'q>>::Arguments>[src]
fn persistent(&self) -> bool[src]
Implementors
impl<'q, DB, A> Execute<'q, DB> for Query<'q, DB, A> where
DB: Database,
A: Send + IntoArguments<'q, DB>, [src]
impl<'q, DB, A> Execute<'q, DB> for Query<'q, DB, A> where
DB: Database,
A: Send + IntoArguments<'q, DB>, [src]fn sql(&self) -> &'q str[src]
fn statement(&self) -> Option<&<DB as HasStatement<'q>>::Statement>[src]
fn take_arguments(&mut self) -> Option<<DB as HasArguments<'q>>::Arguments>[src]
fn persistent(&self) -> bool[src]
impl<'q, DB, F: Send, A: Send> Execute<'q, DB> for Map<'q, DB, F, A> where
DB: Database,
A: IntoArguments<'q, DB>, [src]
impl<'q, DB, F: Send, A: Send> Execute<'q, DB> for Map<'q, DB, F, A> where
DB: Database,
A: IntoArguments<'q, DB>, [src]fn sql(&self) -> &'q str[src]
fn statement(&self) -> Option<&<DB as HasStatement<'q>>::Statement>[src]
fn take_arguments(&mut self) -> Option<<DB as HasArguments<'q>>::Arguments>[src]
fn persistent(&self) -> bool[src]
impl<'q, DB, O: Send, A: Send> Execute<'q, DB> for QueryAs<'q, DB, O, A> where
DB: Database,
A: 'q + IntoArguments<'q, DB>, [src]
impl<'q, DB, O: Send, A: Send> Execute<'q, DB> for QueryAs<'q, DB, O, A> where
DB: Database,
A: 'q + IntoArguments<'q, DB>, [src]fn sql(&self) -> &'q str[src]
fn statement(&self) -> Option<&<DB as HasStatement<'q>>::Statement>[src]
fn take_arguments(&mut self) -> Option<<DB as HasArguments<'q>>::Arguments>[src]
fn persistent(&self) -> bool[src]
impl<'q, DB: Database, O: Send, A: Send> Execute<'q, DB> for QueryScalar<'q, DB, O, A> where
A: 'q + IntoArguments<'q, DB>, [src]
impl<'q, DB: Database, O: Send, A: Send> Execute<'q, DB> for QueryScalar<'q, DB, O, A> where
A: 'q + IntoArguments<'q, DB>, [src]