pub enum TransactionManagerStatus {
Valid(ValidTransactionManagerStatus),
InError,
}
Expand description
Status of the transaction manager
Variants
Valid(ValidTransactionManagerStatus)
Valid status, the manager can run operations
InError
Error status, probably following a broken connection. The manager will no longer run operations
Implementations
sourceimpl TransactionManagerStatus
impl TransactionManagerStatus
sourcepub fn transaction_depth(&self) -> QueryResult<Option<NonZeroU32>>
pub fn transaction_depth(&self) -> QueryResult<Option<NonZeroU32>>
Returns the transaction depth if the transaction manager’s status is valid, or returns
Error::BrokenTransactionManager
if the transaction manager is in error.
sourcepub fn set_in_error(&mut self)
pub fn set_in_error(&mut self)
Sets the transaction manager status to InError
Subsequent attempts to use transaction-related features will result in a
Error::BrokenTransactionManager
error
Trait Implementations
sourceimpl Debug for TransactionManagerStatus
impl Debug for TransactionManagerStatus
Auto Trait Implementations
impl RefUnwindSafe for TransactionManagerStatus
impl Send for TransactionManagerStatus
impl Sync for TransactionManagerStatus
impl Unpin for TransactionManagerStatus
impl UnwindSafe for TransactionManagerStatus
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> IntoSql for T
impl<T> IntoSql for T
sourcefn into_sql<T>(self) -> AsExprOf<Self, T>where
Self: AsExpression<T> + Sized,
T: SqlType + TypedExpressionType,
fn into_sql<T>(self) -> AsExprOf<Self, T>where
Self: AsExpression<T> + Sized,
T: SqlType + TypedExpressionType,
Convert
self
to an expression for Diesel’s query builder. Read moresourcefn as_sql<'a, T>(&'a self) -> AsExprOf<&'a Self, T>where
&'a Self: AsExpression<T>,
T: SqlType + TypedExpressionType,
fn as_sql<'a, T>(&'a self) -> AsExprOf<&'a Self, T>where
&'a Self: AsExpression<T>,
T: SqlType + TypedExpressionType,
Convert
&self
to an expression for Diesel’s query builder. Read more