Struct rsfbclient_rust::RustFbClient
source · pub struct RustFbClient { /* private fields */ }
Expand description
Firebird client implemented in pure rust
Implementations§
Trait Implementations§
source§impl FirebirdClientDbOps for RustFbClient
impl FirebirdClientDbOps for RustFbClient
source§type AttachmentConfig = RustFbClientAttachmentConfig
type AttachmentConfig = RustFbClientAttachmentConfig
Configuration details for attaching to the database.
A user of an implementation of this trait can configure attachment details
(database name, user name, etcetera) and then pass this configuration to the implementation
via this type when a new attachment is requested
source§fn attach_database(
&mut self,
config: &Self::AttachmentConfig,
dialect: Dialect,
no_db_triggers: bool,
) -> Result<DbHandle, FbError>
fn attach_database( &mut self, config: &Self::AttachmentConfig, dialect: Dialect, no_db_triggers: bool, ) -> Result<DbHandle, FbError>
Create a new attachment to a database with the provided configuration
Returns a database handle on success
source§fn detach_database(&mut self, db_handle: &mut DbHandle) -> Result<(), FbError>
fn detach_database(&mut self, db_handle: &mut DbHandle) -> Result<(), FbError>
Disconnect from the database
source§fn drop_database(&mut self, db_handle: &mut DbHandle) -> Result<(), FbError>
fn drop_database(&mut self, db_handle: &mut DbHandle) -> Result<(), FbError>
Drop the database
source§fn create_database(
&mut self,
config: &Self::AttachmentConfig,
page_size: Option<u32>,
dialect: Dialect,
) -> Result<DbHandle, FbError>
fn create_database( &mut self, config: &Self::AttachmentConfig, page_size: Option<u32>, dialect: Dialect, ) -> Result<DbHandle, FbError>
Create the database and attach
Returns a database handle on success
source§impl FirebirdClientSqlOps for RustFbClient
impl FirebirdClientSqlOps for RustFbClient
source§type StmtHandle = StmtHandleData
type StmtHandle = StmtHandleData
A statement handle
source§fn begin_transaction(
&mut self,
db_handle: &mut Self::DbHandle,
confs: TransactionConfiguration,
) -> Result<Self::TrHandle, FbError>
fn begin_transaction( &mut self, db_handle: &mut Self::DbHandle, confs: TransactionConfiguration, ) -> Result<Self::TrHandle, FbError>
Start a new transaction, with the specified transaction parameter buffer
source§fn transaction_operation(
&mut self,
tr_handle: &mut Self::TrHandle,
op: TrOp,
) -> Result<(), FbError>
fn transaction_operation( &mut self, tr_handle: &mut Self::TrHandle, op: TrOp, ) -> Result<(), FbError>
Commit / Rollback a transaction
source§fn exec_immediate(
&mut self,
_db_handle: &mut Self::DbHandle,
tr_handle: &mut Self::TrHandle,
dialect: Dialect,
sql: &str,
) -> Result<(), FbError>
fn exec_immediate( &mut self, _db_handle: &mut Self::DbHandle, tr_handle: &mut Self::TrHandle, dialect: Dialect, sql: &str, ) -> Result<(), FbError>
Execute a sql immediately, without returning rows
source§fn prepare_statement(
&mut self,
db_handle: &mut Self::DbHandle,
tr_handle: &mut Self::TrHandle,
dialect: Dialect,
sql: &str,
) -> Result<(StmtType, Self::StmtHandle), FbError>
fn prepare_statement( &mut self, db_handle: &mut Self::DbHandle, tr_handle: &mut Self::TrHandle, dialect: Dialect, sql: &str, ) -> Result<(StmtType, Self::StmtHandle), FbError>
Allocate and prepare a statement
Returns the statement type and handle
source§fn free_statement(
&mut self,
stmt_handle: &mut Self::StmtHandle,
op: FreeStmtOp,
) -> Result<(), FbError>
fn free_statement( &mut self, stmt_handle: &mut Self::StmtHandle, op: FreeStmtOp, ) -> Result<(), FbError>
Closes or drops a statement
source§fn execute(
&mut self,
_db_handle: &mut Self::DbHandle,
tr_handle: &mut Self::TrHandle,
stmt_handle: &mut Self::StmtHandle,
params: Vec<SqlType>,
) -> Result<usize, FbError>
fn execute( &mut self, _db_handle: &mut Self::DbHandle, tr_handle: &mut Self::TrHandle, stmt_handle: &mut Self::StmtHandle, params: Vec<SqlType>, ) -> Result<usize, FbError>
Execute the prepared statement with parameters
and returns the affected rows count
Auto Trait Implementations§
impl Freeze for RustFbClient
impl !RefUnwindSafe for RustFbClient
impl Send for RustFbClient
impl Sync for RustFbClient
impl Unpin for RustFbClient
impl !UnwindSafe for RustFbClient
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