PHP Class Aerys\VhostContainer

Inheritance: implements Countable, implements aerys\Monitor
Afficher le fichier Open project: amphp/aerys Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( aerys\HttpDriver $driver )
__debugInfo ( )
count ( )
getBindableAddresses ( ) : array Retrieve an array of unique socket addresses on which hosts should listen
getDefaultHost ( ) : Vhost Retrieve the group's default host
getTlsBindingsByAddress ( ) : array Retrieve stream encryption settings by bind address
monitor ( ) : array
selectHost ( InternalRequest $ireq ) : Vhost | null Select a virtual host match for the specified request according to RFC 7230 criteria
selectHttpDriver ( $address, $port ) Select the suited HttpDriver instance, filtered by address and port pair
setupHttpDrivers ( $args )
use ( Vhost $vhost ) : void Add a virtual host to the collection

Private Methods

Méthode Description
addHttpDriver ( Vhost $vhost )
preventCryptoSocketConflict ( Vhost $new )
selectHostByAuthority ( InternalRequest $ireq )

Method Details

__construct() public méthode

public __construct ( aerys\HttpDriver $driver )
$driver aerys\HttpDriver

__debugInfo() public méthode

public __debugInfo ( )

count() public méthode

public count ( )

getBindableAddresses() public méthode

Retrieve an array of unique socket addresses on which hosts should listen
public getBindableAddresses ( ) : array
Résultat array Returns an array of unique host addresses in the form: tcp://ip:port

getDefaultHost() public méthode

Retrieve the group's default host
public getDefaultHost ( ) : Vhost
Résultat Vhost

getTlsBindingsByAddress() public méthode

Retrieve stream encryption settings by bind address
public getTlsBindingsByAddress ( ) : array
Résultat array

monitor() public méthode

public monitor ( ) : array
Résultat array

selectHost() public méthode

Select a virtual host match for the specified request according to RFC 7230 criteria
public selectHost ( InternalRequest $ireq ) : Vhost | null
$ireq InternalRequest
Résultat Vhost | null Returns a Vhost object and boolean TRUE if a valid host selected, FALSE otherwise

selectHttpDriver() public méthode

Select the suited HttpDriver instance, filtered by address and port pair
public selectHttpDriver ( $address, $port )

setupHttpDrivers() public méthode

public setupHttpDrivers ( $args )

use() public méthode

Add a virtual host to the collection
public use ( Vhost $vhost ) : void
$vhost Vhost
Résultat void