Keyboard shortcuts

Press or to navigate between chapters

Press ? to show this help

Press Esc to hide this help

InternalTrait

Fully qualified path: openzeppelin_security::pausable::PausableComponent::InternalTrait

pub trait InternalTrait<TContractState, +HasComponent<TContractState>>

Trait functions

assert_not_paused

Makes a function only callable when the contract is not paused.

Fully qualified path: openzeppelin_security::pausable::PausableComponent::InternalTrait::assert_not_paused

fn assert_not_paused(self: @ComponentState<TContractState>)

assert_paused

Makes a function only callable when the contract is paused.

Fully qualified path: openzeppelin_security::pausable::PausableComponent::InternalTrait::assert_paused

fn assert_paused(self: @ComponentState<TContractState>)

pause

Triggers a stopped state.

Requirements:

  • The contract is not paused.

Emits a Paused event.

Fully qualified path: openzeppelin_security::pausable::PausableComponent::InternalTrait::pause

fn pause(ref self: ComponentState<TContractState>)

unpause

Lifts the pause on the contract.

Requirements:

  • The contract is paused.

Emits an Unpaused event.

Fully qualified path: openzeppelin_security::pausable::PausableComponent::InternalTrait::unpause

fn unpause(ref self: ComponentState<TContractState>)