Свойство | Type | Description | |
---|---|---|---|
$_currentUsageEvent | array | ||
$_dataPrivacyOn | boolean | ||
$_optedOut | boolean | ||
$_saltpath | string |
Méthode | Description | |
---|---|---|
__construct ( ) | Constructor. | |
_downloadStatsCacheMiss ( $cache, $pubObjectId ) : array | Callback to fill cache with data, if empty. | |
_getColor ( $num ) : string | Return a color RGB code to be used in the graph. | |
_getDownloadStats ( $pubObjectId ) : array | Get prepared download statistics from the DB | |
_hashIp ( $ip, $salt ) : string | boolean | Hash (SHA256) the given IP using the given SALT. | |
_writeUsageEventInLogFile ( $usageEvent ) | ||
addJavascriptData ( $data, $pubObjectType, $pubObjectId, $contexts ) : null | Add a data set to the script data output | |
callbackLoadCategory ( $hookName, $args ) | ||
callbackLoadHandler ( $hookName, $args ) | ||
callbackParseCronTab ( $hookName, $args ) | ||
getActions ( $request, $verb ) | ||
getAllDownloadsStats ( $pubObjectId, $stats = [] ) | Retrieve the allDownloads dataset from the download stats | |
getDescription ( ) | ||
getDisplayName ( ) | ||
getFilesPath ( ) : string | Get the plugin's files path. | |
getGeoLocationTool ( ) : mixed | Get the geolocation tool to process geo localization data. | |
getInstallSchemaFile ( ) | ||
getInstallSitePluginSettingsFile ( ) | ||
getReportPlugin ( ) | Get the report plugin object that implements the metric type details. | |
getSaltpath ( ) : string | Get the path to the salt file. | |
getTemplate ( $args, $template, $smarty ) : string | Fetch a template with the requested params | |
getTemplatePath ( $inCore = false ) | ||
getUsageEventCurrentDayLogName ( ) : string | Get current day usage event log name. | |
getUsageEventLogsPath ( ) : string | Get the plugin's usage event logs path. | |
isSitePlugin ( ) | ||
loadJavascript ( $contexts ) : null | Load the JavaScript assets and pass data to the scripts | |
logUsageEvent ( $hookName, $args ) : boolean | Log the usage event into a file. | |
manage ( $args, $request ) | ||
register ( $category, $path ) | ||
statisticsDisplayCallback ( $hookName, $params ) : boolean | Adds/renders the submission level metrics markup, if any stats. | |
templateManagerCallback ( $hookName, $params ) | Template manager hook callback. | |
validateSaltpath ( $saltpath ) : boolean | Validate that the path of the salt file exists and is writable. |
public _downloadStatsCacheMiss ( $cache, $pubObjectId ) : array | ||
$cache | FileCache | |
$pubObjectId | int | |
Résultat | array |
public _getDownloadStats ( $pubObjectId ) : array | ||
$pubObjectId | integer | |
Résultat | array |
public _writeUsageEventInLogFile ( $usageEvent ) | ||
$usageEvent | array |
public addJavascriptData ( $data, $pubObjectType, $pubObjectId, $contexts ) : null | ||
$data | array JS data to pass to the scripts | |
$pubObjectType | string The type of object this data is for | |
$pubObjectId | string The id of the object this data is for | |
$contexts | string|array Contexts in which to load the scripts. | |
Résultat | null |
public getAllDownloadsStats ( $pubObjectId, $stats = [] ) | ||
$pubObjectId | int ID of the object to get stats for | |
$stats | array Optionally pass in stats that have already been fetched from _getDownloadStats(). |
public getFilesPath ( ) : string | ||
Résultat | string |
public getGeoLocationTool ( ) : mixed | ||
Résultat | mixed | GeoLocationTool object or null |
public getReportPlugin ( ) |
public getSaltpath ( ) : string | ||
Résultat | string |
public getTemplate ( $args, $template, $smarty ) : string | ||
$args | array Variables to assign to the template | |
$template | array Template file name | |
$smarty | object Smarty template object | |
Résultat | string |
public getUsageEventCurrentDayLogName ( ) : string | ||
Résultat | string |
public getUsageEventLogsPath ( ) : string | ||
Résultat | string |
public loadJavascript ( $contexts ) : null | ||
$contexts | string|array Contexts in which to load the scripts. | |
Résultat | null |
public logUsageEvent ( $hookName, $args ) : boolean | ||
$hookName | string | |
$args | array | |
Résultat | boolean |
public statisticsDisplayCallback ( $hookName, $params ) : boolean | ||
$hookName | string | |
$params | ||
Résultat | boolean |
public templateManagerCallback ( $hookName, $params ) | ||
$hookName | string | |
$params | array |
public validateSaltpath ( $saltpath ) : boolean | ||
$saltpath | string | |
Résultat | boolean |