pub struct PostgresTransaction { /* private fields */ }Implementations§
Source§impl PostgresTransaction
impl PostgresTransaction
pub fn new(connection: PostgresConnection) -> Self
pub async fn execute( &self, sql: &str, params: &[DsValue], ) -> Result<u64, DsError>
pub async fn query( &self, sql: &str, params: &[DsValue], ) -> Result<Vec<DsValue>, DsError>
pub async fn commit(self) -> Result<(), DsError>
pub async fn rollback(self) -> Result<(), DsError>
Auto Trait Implementations§
impl Freeze for PostgresTransaction
impl RefUnwindSafe for PostgresTransaction
impl Send for PostgresTransaction
impl Sync for PostgresTransaction
impl Unpin for PostgresTransaction
impl UnwindSafe for PostgresTransaction
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more