Méthode | Description | |
---|---|---|
getBrowser ( string $userAgent = null ) : stdClass | parses the given user agent to get the information about the browser | |
getCache ( ) : BrowscapPHP\Cache\BrowscapCacheInterface | Gets a cache instance | |
getFormatter ( ) : BrowscapPHP\Formatter\FormatterInterface | ||
getLogger ( ) : Psr\Log\LoggerInterface | returns a logger instance | |
getParser ( ) : BrowscapPHP\Parser\ParserInterface | returns an instance of the used parser class | |
setCache ( BrowscapPHP\Cache\BrowscapCacheInterface | WurflCache\Adapter\AdapterInterface $cache ) : |
Sets a cache instance | |
setFormatter ( BrowscapPHP\Formatter\FormatterInterface $formatter ) : |
Set theformatter instance to use for the getBrowser() result | |
setLogger ( Psr\Log\LoggerInterface $logger ) : |
Sets a logger instance | |
setParser ( BrowscapPHP\Parser\ParserInterface $parser ) : |
Sets the parser instance to use |
public getBrowser ( string $userAgent = null ) : stdClass | ||
$userAgent | string | the user agent string |
Résultat | stdClass | the object containing the browsers details. Array if $return_array is set to true. |
public getCache ( ) : BrowscapPHP\Cache\BrowscapCacheInterface | ||
Résultat | BrowscapPHP\Cache\BrowscapCacheInterface |
public getFormatter ( ) : BrowscapPHP\Formatter\FormatterInterface | ||
Résultat | BrowscapPHP\Formatter\FormatterInterface |
public getLogger ( ) : Psr\Log\LoggerInterface | ||
Résultat | Psr\Log\LoggerInterface |
public getParser ( ) : BrowscapPHP\Parser\ParserInterface | ||
Résultat | BrowscapPHP\Parser\ParserInterface |
public setCache ( BrowscapPHP\Cache\BrowscapCacheInterface | WurflCache\Adapter\AdapterInterface $cache ) : |
||
$cache | BrowscapPHP\Cache\BrowscapCacheInterface | WurflCache\Adapter\AdapterInterface | |
Résultat |
public setFormatter ( BrowscapPHP\Formatter\FormatterInterface $formatter ) : |
||
$formatter | BrowscapPHP\Formatter\FormatterInterface | |
Résultat |
public setLogger ( Psr\Log\LoggerInterface $logger ) : |
||
$logger | Psr\Log\LoggerInterface | |
Résultat |
public setParser ( BrowscapPHP\Parser\ParserInterface $parser ) : |
||
$parser | BrowscapPHP\Parser\ParserInterface | |
Résultat |