PHP Class AppserverIo\Appserver\PersistenceContainer\StandardGarbageCollector

Inheritance: extends AppserverIo\Appserver\Core\AbstractDaemonThread
Show file Open project: appserver-io/appserver Class Usage Examples

Public Methods

Method Description
bootstrap ( ) : void This method will be invoked before the while() loop starts and can be used to implement some bootstrap functionality.
collectGarbage ( ) : void Collects the SFSBs that has been timed out
getApplication ( ) : AppserverIo\Psr\Application\ApplicationInterface Returns the application instance.
injectApplication ( AppserverIo\Psr\Application\ApplicationInterface $application ) : void Injects the application instance.
iterate ( integer $timeout ) : void This is invoked on every iteration of the daemons while() loop.
log ( mixed $level, string $message, array $context = [] ) : void This is a very basic method to log some stuff by using the error_log() method of PHP.

Method Details

bootstrap() public method

This method will be invoked before the while() loop starts and can be used to implement some bootstrap functionality.
public bootstrap ( ) : void
return void

collectGarbage() public method

Collects the SFSBs that has been timed out
public collectGarbage ( ) : void
return void

getApplication() public method

Returns the application instance.
public getApplication ( ) : AppserverIo\Psr\Application\ApplicationInterface
return AppserverIo\Psr\Application\ApplicationInterface The application instance

injectApplication() public method

Injects the application instance.
public injectApplication ( AppserverIo\Psr\Application\ApplicationInterface $application ) : void
$application AppserverIo\Psr\Application\ApplicationInterface The application instance
return void

iterate() public method

This is invoked on every iteration of the daemons while() loop.
public iterate ( integer $timeout ) : void
$timeout integer The timeout before the daemon wakes up
return void

log() public method

This is a very basic method to log some stuff by using the error_log() method of PHP.
public log ( mixed $level, string $message, array $context = [] ) : void
$level mixed The log level to use
$message string The message we want to log
$context array The context we of the message
return void