PHP Class AppserverIo\Appserver\ServletEngine\AbstractServletEngine

Author: Bernhard Wick ([email protected])
Author: Tim Wagner ([email protected])
Inheritance: implements AppserverIo\WebServer\Interfaces\HttpModuleInterface
Mostrar archivo Open project: appserver-io/appserver

Protected Properties

Property Type Description
$applications array Storage with the available applications.
$dependencies array Storage with the available applications.
$handlers array Storage handlers registered in the web server.
$valves array Storage for the servlet engines valves that handles the request.

Public Methods

Method Description
findRequestedApplication ( AppserverIo\Server\Interfaces\RequestContextInterface $requestContext ) : null | AppserverIo\Psr\Application\ApplicationInterface Will try to find the application based on the context path taken from the requested filename.
getApplications ( ) : array Returns the initialized applications.
getContainer ( ) : AppserverIo\Appserver\Core\Interfaces\ContainerInterface Returns the container instance.
getDependencies ( ) : array Returns an array of module names which should be executed first.
getHandlers ( ) : array Returns the initialized web server handlers.
getServerContext ( ) : AppserverIo\Server\Interfaces\ServerContextInterface Returns the server context instance.
getValves ( ) : array Returns the initialized valves.
initApplications ( ) : void Initialize the applications.
initHandlers ( ) : void Initialize the web server handlers.
initValves ( ) : void Initialize the valves that handles the requests.
logCriticalException ( Exception $e ) : void Helper method that writes critical system exceptions to the system logger if configured.
logDebugException ( Exception $e ) : void Helper method that writes debug system exceptions to the system logger if configured.
logErrorException ( Exception $e ) : void Helper method that writes system exceptions to the system logger if configured.
prepare ( ) : boolean Prepares the module for upcoming request in specific context

Method Details

findRequestedApplication() public method

Will return the found application on success and throw an exception if nothing could be found
public findRequestedApplication ( AppserverIo\Server\Interfaces\RequestContextInterface $requestContext ) : null | AppserverIo\Psr\Application\ApplicationInterface
$requestContext AppserverIo\Server\Interfaces\RequestContextInterface Context of the current request
return null | AppserverIo\Psr\Application\ApplicationInterface

getApplications() public method

Returns the initialized applications.
public getApplications ( ) : array
return array The initialized application instances

getContainer() public method

Returns the container instance.
public getContainer ( ) : AppserverIo\Appserver\Core\Interfaces\ContainerInterface
return AppserverIo\Appserver\Core\Interfaces\ContainerInterface The container instance

getDependencies() public method

Returns an array of module names which should be executed first.
public getDependencies ( ) : array
return array The module names this module depends on

getHandlers() public method

Returns the initialized web server handlers.
public getHandlers ( ) : array
return array The initialized web server handlers

getServerContext() public method

Returns the server context instance.
public getServerContext ( ) : AppserverIo\Server\Interfaces\ServerContextInterface
return AppserverIo\Server\Interfaces\ServerContextInterface The actual server context instance

getValves() public method

Returns the initialized valves.
public getValves ( ) : array
return array The initialized valves

initApplications() public method

Initialize the applications.
public initApplications ( ) : void
return void

initHandlers() public method

Initialize the web server handlers.
public initHandlers ( ) : void
return void

initValves() public method

Initialize the valves that handles the requests.
public initValves ( ) : void
return void

logCriticalException() public method

Helper method that writes critical system exceptions to the system logger if configured.
public logCriticalException ( Exception $e ) : void
$e Exception The exception to be logged
return void

logDebugException() public method

Helper method that writes debug system exceptions to the system logger if configured.
public logDebugException ( Exception $e ) : void
$e Exception The exception to be logged
return void

logErrorException() public method

Helper method that writes system exceptions to the system logger if configured.
public logErrorException ( Exception $e ) : void
$e Exception The exception to be logged
return void

prepare() public method

Prepares the module for upcoming request in specific context
public prepare ( ) : boolean
return boolean

Property Details

$applications protected_oe property

Storage with the available applications.
protected array $applications
return array

$dependencies protected_oe property

Storage with the available applications.
protected array $dependencies
return array

$handlers protected_oe property

Storage handlers registered in the web server.
protected array $handlers
return array

$valves protected_oe property

Storage for the servlet engines valves that handles the request.
protected array $valves
return array