pub struct SqlReadContext<'connection> { /* private fields */ }Expand description
Host SQL against Coven’s retained database connection.
The connection remains private. This context exposes query operations while preventing callers from changing connection configuration or starting an independent transaction.
ⓘ
fn cannot_write(sql: coven::SqlReadContext<'_>) {
sql.execute("DELETE FROM notes", []);
}Implementations§
Source§impl<'connection> SqlReadContext<'connection>
impl<'connection> SqlReadContext<'connection>
Auto Trait Implementations§
impl<'connection> Freeze for SqlReadContext<'connection>
impl<'connection> !RefUnwindSafe for SqlReadContext<'connection>
impl<'connection> !Send for SqlReadContext<'connection>
impl<'connection> !Sync for SqlReadContext<'connection>
impl<'connection> Unpin for SqlReadContext<'connection>
impl<'connection> UnsafeUnpin for SqlReadContext<'connection>
impl<'connection> !UnwindSafe for SqlReadContext<'connection>
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