PHP Class UserAgentParser\Provider\AbstractProvider

Exibir arquivo Open project: ThaDafinser/UserAgentParser

Protected Properties

Property Type Description
$allDetectionCapabilities array Per default the provider cannot detect anything Activate them in $detectionCapabilities
$defaultValues
$detectionCapabilities array Set this in each Provider implementation
$homepage string Homepage of the provider
$name string Name of the provider
$packageName string Composer package name

Public Methods

Method Description
getDetectionCapabilities ( ) : array What kind of capabilities this provider can detect
getHomepage ( ) : string Get the homepage
getName ( ) : string Return the name of the provider
getPackageName ( ) : string Get the package name
getUpdateDate ( ) : DateTim\DateTime Get the last change date of the provider
getVersion ( ) : string Return the version of the provider
parse ( string $userAgent, array $headers = [] ) : UserAgent Parse the given user agent and return a result if possible

Protected Methods

Method Description
checkIfInstalled ( )
getRealResult ( $value, $group = null, $part = null )
isRealResult ( mixed $value, string $group = null, string $part = null ) : boolean

Method Details

checkIfInstalled() protected method

protected checkIfInstalled ( )

getDetectionCapabilities() public method

What kind of capabilities this provider can detect
public getDetectionCapabilities ( ) : array
return array

getHomepage() public method

Get the homepage
public getHomepage ( ) : string
return string

getName() public method

Return the name of the provider
public getName ( ) : string
return string

getPackageName() public method

Get the package name
public getPackageName ( ) : string
return string null

getRealResult() protected method

protected getRealResult ( $value, $group = null, $part = null )

getUpdateDate() public method

Get the last change date of the provider
public getUpdateDate ( ) : DateTim\DateTime
return DateTim\DateTime null

getVersion() public method

Return the version of the provider
public getVersion ( ) : string
return string null

isRealResult() protected method

protected isRealResult ( mixed $value, string $group = null, string $part = null ) : boolean
$value mixed
$group string
$part string
return boolean

parse() abstract public method

Parse the given user agent and return a result if possible
abstract public parse ( string $userAgent, array $headers = [] ) : UserAgent
$userAgent string
$headers array
return UserAgentParser\Model\UserAgent

Property Details

$allDetectionCapabilities protected_oe property

Per default the provider cannot detect anything Activate them in $detectionCapabilities
protected array $allDetectionCapabilities
return array

$defaultValues protected_oe property

protected $defaultValues

$detectionCapabilities protected_oe property

Set this in each Provider implementation
protected array $detectionCapabilities
return array

$homepage protected_oe property

Homepage of the provider
protected string $homepage
return string

$name protected_oe property

Name of the provider
protected string $name
return string

$packageName protected_oe property

Composer package name
protected string $packageName
return string