pub struct CorrosionClient { /* private fields */ }Implementations§
Source§impl CorrosionClient
impl CorrosionClient
pub fn new<P: AsRef<Path>>(api_addr: SocketAddr, db_path: P) -> Self
pub fn pool(&self) -> &Pool<RusqliteConnManager>
Methods from Deref<Target = CorrosionApiClient>§
pub async fn query(&self, statement: &Statement) -> Result<Body, Error>
pub async fn watch( &self, statement: &Statement, ) -> Result<(Uuid, impl Stream<Item = Result<QueryEvent>>), Error>
pub async fn watched_query( &self, id: Uuid, ) -> Result<impl Stream<Item = Result<QueryEvent>>, Error>
pub async fn execute( &self, statements: &[Statement], ) -> Result<RqliteResponse, Error>
pub async fn schema( &self, statements: &[Statement], ) -> Result<RqliteResponse, Error>
pub async fn schema_from_paths<P: AsRef<Path>>( &self, schema_paths: &[P], ) -> Result<RqliteResponse, Error>
Trait Implementations§
Source§impl Clone for CorrosionClient
impl Clone for CorrosionClient
Source§fn clone(&self) -> CorrosionClient
fn clone(&self) -> CorrosionClient
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for CorrosionClient
impl !RefUnwindSafe for CorrosionClient
impl Send for CorrosionClient
impl Sync for CorrosionClient
impl Unpin for CorrosionClient
impl !UnwindSafe for CorrosionClient
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