pub fn ready_to_stop(&self) -> bool {
        match &self.status {
            CanisterStatus::Running { .. } => false,
            CanisterStatus::Stopping {
                call_context_manager,
                ..
            } => {
                call_context_manager.callbacks().is_empty()
                    && call_context_manager.call_contexts().is_empty()
            }
            CanisterStatus::Stopped => true,
        }
    }
/// Returns a boolean whether the system state is ready to be `Stopped`.
/// Only relevant for a `Stopping` system state.
Returns a boolean whether the system state is ready to be `Stopped`.
Only relevant for a `Stopping` system state.
Returns a boolean whether the system state is ready to be ` Stopped ` . Only relevant for a ` Stopping ` system state .
pub fn ready_to_stop(&self) -> bool {
        match &self.status {
            CanisterStatus::Running { .. } => false,
            CanisterStatus::Stopping {
                call_context_manager,
                ..
            } => {
                call_context_manager.callbacks().is_empty()
                    && call_context_manager.call_contexts().is_empty()
            }
            CanisterStatus::Stopped => true,
        }
    }
pub fn ready_to_stop ( & self ) -> bool { match & self . status { CanisterStatus :: Running { .. } => false , CanisterStatus :: Stopping { call_context_manager , .. } => { call_context_manager . callbacks ( ) . is_empty ( ) && call_context_manager . call_contexts ( ) . is_empty ( ) } CanisterStatus :: Stopped => true , } }
Returns a boolean whether the system state is ready to be `Stopped`.
Returns a boolean whether the system state is ready to be ` Stopped ` .
&self
&self