Moodle APIs  3.8
Moodle 3.8.6 (Build: 20201109)
Static Public Member Functions | Static Protected Member Functions | Static Protected Attributes | List of all members
core_shutdown_manager Class Reference

Shutdown management class. More...

Static Public Member Functions

static initialize ()
 Register self as main shutdown handler. More...
 
static register_function ($callback, array $params=null)
 Register custom shutdown function. More...
 
static shutdown_handler ()
 
  • do NOT call directly.

 
static signal_handler ($signo)
 Signal handler for SIGINT, and SIGTERM. More...
 

Static Protected Member Functions

static request_shutdown ()
 Standard shutdown sequence.
 

Static Protected Attributes

static array $callbacks = array()
 list of custom callbacks
 
static bool $registered = false
 is this manager already registered?
 

Detailed Description

Shutdown management class.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Member Function Documentation

◆ initialize()

static core_shutdown_manager::initialize ( )
static

Register self as main shutdown handler.

to be called from lib/setup.php only!

◆ register_function()

static core_shutdown_manager::register_function (   $callback,
array  $params = null 
)
static

Register custom shutdown function.

Parameters
callable$callback
array$params

◆ signal_handler()

static core_shutdown_manager::signal_handler (   $signo)
static

Signal handler for SIGINT, and SIGTERM.

Parameters
int$signoThe signal being handled

The documentation for this class was generated from the following file: