Bearsampp 2025.8.29
Loading...
Searching...
No Matches
ActionManualRestart Class Reference

Public Member Functions

 __construct ($args)

Detailed Description

Class ActionManualRestart

This class handles the manual restart of services in the Bearsampp application. It stops all running services, kills all related processes, and sets the application to restart.

Definition at line 18 of file class.action.manualRestart.php.

Constructor & Destructor Documentation

◆ __construct()

__construct ( $args)

ActionManualRestart constructor.

Parameters
array$argsArguments passed to the constructor.

This constructor initializes the manual restart process by performing the following steps:

  1. Starts the loading process.
  2. Deletes all services managed by Bearsampp.
  3. Kills all related processes.
  4. Sets the application to restart.
  5. Stops the loading process.

Definition at line 32 of file class.action.manualRestart.php.

33 {
35
36 Util::logTrace("Starting ActionManualRestart constructor");
37
38 // Start the loading process
39 Util::logTrace("Starting loading process");
41
42 // Delete all services managed by Bearsampp
43 Util::logTrace("Deleting all services managed by Bearsampp");
44 foreach ($bearsamppBins->getServices() as $sName => $service) {
45 Util::logTrace("Deleting service: " . $sName);
46 $service->delete();
47 }
48
49 // Kill all related processes
50 Util::logTrace("Killing all related processes");
52
53 // Set the application to restart
54 Util::logTrace("Setting application to restart");
56
57 // Stop the loading process
58 Util::logTrace("Stopping loading process");
60 }
global $bearsamppBins
global $bearsamppCore
static logTrace($data, $file=null)
static startLoading()
static stopLoading()
static killBins($refreshProcs=false)

References $bearsamppBins, $bearsamppCore, Win32Ps\killBins(), Util\logTrace(), ActionExec\RESTART, Util\startLoading(), and Util\stopLoading().


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