PHP Class BenConstable\Localize\Determiners\Host

Inheritance: extends Determiner
Show file Open project: benconstable/laravel-localize-middleware Class Usage Examples

Public Methods

Method Description
__construct ( Collection $hostMapping ) : void Constructor.
determineLocale ( Illuminate\Http\Request $request ) : string Determine the locale from the current host.

Method Details

__construct() public method

Constructor.
public __construct ( Collection $hostMapping ) : void
$hostMapping Illuminate\Support\Collection Locale to host mapping
return void

determineLocale() public method

Determine the locale from the current host.
public determineLocale ( Illuminate\Http\Request $request ) : string
$request Illuminate\Http\Request
return string