PHP Class Thms\Config\Environment

Mostra file Open project: themosis/themosis

Protected Properties

Property Type Description
$locations array | Closur\Closure Environment locations.

Public Methods

Method Description
__construct ( array | Closur\Closure $locations ) Init the Environment class.
which ( string $hostname = '' ) : string Find in which environment we are.

Protected Methods

Method Description
match ( string $host, string $hostname ) : boolean Check if a host is matching a pattern.

Method Details

__construct() public method

Init the Environment class.
public __construct ( array | Closur\Closure $locations )
$locations array | Closur\Closure Environment locations - Detection.

match() protected method

Check if a host is matching a pattern.
protected match ( string $host, string $hostname ) : boolean
$host string The regular expression pattern host to use.
$hostname string The host name.
return boolean

which() public method

Find in which environment we are.
public which ( string $hostname = '' ) : string
$hostname string The hostname to compare with.
return string

Property Details

$locations protected_oe property

Environment locations.
protected array|Closure,Closur $locations
return array | Closur\Closure