pub trait PauseModule: ContractBase + Sizedwhere
for<'b> Self::BigUint: BigUintApi + AddAssign<&'b Self::BigUint> + SubAssign<&'b Self::BigUint> + MulAssign<&'b Self::BigUint> + DivAssign<&'b Self::BigUint> + RemAssign<&'b Self::BigUint> + BitAndAssign<&'b Self::BigUint> + BitOrAssign<&'b Self::BigUint> + BitXorAssign<&'b Self::BigUint>,
for<'a, 'b> &'a Self::BigUint: Add<&'b Self::BigUint, Output = Self::BigUint> + Sub<&'b Self::BigUint, Output = Self::BigUint> + Mul<&'b Self::BigUint, Output = Self::BigUint> + Div<&'b Self::BigUint, Output = Self::BigUint> + Rem<&'b Self::BigUint, Output = Self::BigUint> + BitAnd<&'b Self::BigUint, Output = Self::BigUint> + BitOr<&'b Self::BigUint, Output = Self::BigUint> + BitXor<&'b Self::BigUint, Output = Self::BigUint> + Shr<usize, Output = Self::BigUint> + Shl<usize, Output = Self::BigUint>,
for<'b> Self::BigInt: BigIntApi + AddAssign<&'b Self::BigInt> + SubAssign<&'b Self::BigInt> + MulAssign<&'b Self::BigInt> + DivAssign<&'b Self::BigInt> + RemAssign<&'b Self::BigInt>,
for<'a, 'b> &'a Self::BigInt: Add<&'b Self::BigInt, Output = Self::BigInt> + Sub<&'b Self::BigInt, Output = Self::BigInt> + Mul<&'b Self::BigInt, Output = Self::BigInt> + Div<&'b Self::BigInt, Output = Self::BigInt> + Rem<&'b Self::BigInt, Output = Self::BigInt>,{
// Required methods
fn is_paused(&self) -> bool;
fn set_paused(&self, paused: bool);
// Provided methods
fn not_paused(&self) -> bool { ... }
fn pause_endpoint(&self) -> SCResult<()> { ... }
fn unpause_endpoint(&self) -> SCResult<()> { ... }
}Expand description
The module deals with temporarily pausing contract operations. It provides a flag that contracts can use to check if owner decided to pause the entire contract. Use the features module for more granular on/off switches.
Required Methods§
Provided Methods§
fn not_paused(&self) -> bool
fn pause_endpoint(&self) -> SCResult<()>
fn unpause_endpoint(&self) -> SCResult<()>
Object Safety§
This trait is not object safe.