public function shutdown(string $runlevel)
    {
        switch ($runlevel) {
            case self::RUNLEVEL_COMPILETIME:
                $this->emitFinishedCompiletimeRun();
                break;
            case self::RUNLEVEL_RUNTIME:
                $this->emitFinishedRuntimeRun();
                break;
        }
        $this->emitBootstrapShuttingDown($runlevel);
    }
public function shutdown(string $runlevel)
    {
        switch ($runlevel) {
            case self::RUNLEVEL_COMPILETIME:
                $this->emitFinishedCompiletimeRun();
                break;
            case self::RUNLEVEL_RUNTIME:
                $this->emitFinishedRuntimeRun();
                break;
        }
        $this->emitBootstrapShuttingDown($runlevel);
    }
public function shutdown ( string $ runlevel ) { switch ( $ runlevel ) { case self :: RUNLEVEL_COMPILETIME : $ this -> emitFinishedCompiletimeRun ( ) ; break ; case self :: RUNLEVEL_RUNTIME : $ this -> emitFinishedRuntimeRun ( ) ; break ; } $ this -> emitBootstrapShuttingDown ( $ runlevel ) ; }
Initiates the shutdown procedure to safely close all connections, save
modified data and commit other tasks necessary to cleanly exit Flow.

This method should be called by a request handler after a successful run.
Control is returned to the request handler which can exit the application
as it sees fit.

@param string $runlevel one of the RUNLEVEL_* constants
@return void
@api
Initiates the shutdown procedure to safely close all connections save modified data and commit other tasks necessary to cleanly exit Flow .