PHP Class Piwik\Plugins\DevicesDetection\API

Inheritance: extends Piwik\Plugin\API
Datei anzeigen Open project: piwik/piwik Class Usage Examples

Public Methods

Method Description
getBrand ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by device manufacturer name
getBrowserEngines ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by Browser engine (eg. Trident, Gecko, Blink,.
getBrowserFamilies ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by Browser family (eg. Firefox, InternetExplorer)
getBrowserVersions ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by Browser version (eg. Firefox 20, Safari 6.0)
getBrowsers ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by Browser (Without version)
getModel ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by device model
getOsFamilies ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by OS family (eg. Windows, Android, Linux)
getOsVersions ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by OS version (eg. Android 4.0, Windows 7)
getType ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable Gets datatable displaying number of visits by device type (eg. desktop, smartphone, tablet)

Protected Methods

Method Description
ensureDefaultRowsInTable ( $dataTable )
getDataTable ( string $name, integer $idSite, string $period, string $date, string $segment ) : DataTable
mergeDataTables ( Piwik\DataTable\DataTableInterface $dataTable, Piwik\DataTable\DataTableInterface $dataTable2 ) : Piwik\DataTable\DataTableInterface That methods handles the fallback to version datatables to calculate those without versions.

Method Details

ensureDefaultRowsInTable() protected method

protected ensureDefaultRowsInTable ( $dataTable )

getBrand() public method

Gets datatable displaying number of visits by device manufacturer name
public getBrand ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

getBrowserEngines() public method

..)
public getBrowserEngines ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

getBrowserFamilies() public method

Gets datatable displaying number of visits by Browser family (eg. Firefox, InternetExplorer)
Deprecation: since 2.9.0 Use {@link getBrowsers} instead.
public getBrowserFamilies ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

getBrowserVersions() public method

Gets datatable displaying number of visits by Browser version (eg. Firefox 20, Safari 6.0)
public getBrowserVersions ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

getBrowsers() public method

Gets datatable displaying number of visits by Browser (Without version)
public getBrowsers ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

getDataTable() protected method

protected getDataTable ( string $name, integer $idSite, string $period, string $date, string $segment ) : DataTable
$name string
$idSite integer
$period string
$date string
$segment string
return Piwik\DataTable

getModel() public method

Gets datatable displaying number of visits by device model
public getModel ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

getOsFamilies() public method

Gets datatable displaying number of visits by OS family (eg. Windows, Android, Linux)
public getOsFamilies ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

getOsVersions() public method

Gets datatable displaying number of visits by OS version (eg. Android 4.0, Windows 7)
public getOsVersions ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

getType() public method

Gets datatable displaying number of visits by device type (eg. desktop, smartphone, tablet)
public getType ( integer $idSite, string $period, string $date, boolean | string $segment = false ) : DataTable
$idSite integer
$period string
$date string
$segment boolean | string
return Piwik\DataTable

mergeDataTables() protected method

Unlike DevicesDetection plugin now, the UserSettings plugin did not store archives holding the os and browser data without their version number. The "version-less" reports were always generated out of the "version-containing" archives . For big archives (month/year) that ment that some of the data was truncated, due to the datatable entry limit. To avoid that data loss / inaccuracy in the future, DevicesDetection plugin will also store archives without the version. For data archived before DevicesDetection plugin was enabled, those archives do not exist, so we try to calculate them here from the "version-containing" reports if possible.
protected mergeDataTables ( Piwik\DataTable\DataTableInterface $dataTable, Piwik\DataTable\DataTableInterface $dataTable2 ) : Piwik\DataTable\DataTableInterface
$dataTable Piwik\DataTable\DataTableInterface
$dataTable2 Piwik\DataTable\DataTableInterface
return Piwik\DataTable\DataTableInterface