PHP Класс Piwik\Plugins\Installation\Rule_checkUserPrivileges

The following privileges are required for Piwik to run: - CREATE - ALTER - SELECT - INSERT - UPDATE - DELETE - DROP - CREATE TEMPORARY TABLES
Наследование: extends HTML_QuickForm2_Rul\HTML_QuickForm2_Rule
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
getRequiredPrivileges ( ) : array Returns an array describing the database privileges required for Piwik to run. The array maps privilege names with one or more SQL queries that can be used to test if the current user has the privilege.
getRequiredPrivilegesPretty ( ) : string Returns a string description of the database privileges required for Piwik to run.
validateOwner ( ) Checks that the DB user entered in the form has the necessary privileges for Piwik to run.

Приватные методы

Метод Описание
createDatabaseObject ( ) : array Creates a database object using the connection information entered in the form.
dropExtraTables ( Piwik\Db $db ) Drops the tables created by the privilege checking queries, if they exist.
isAccessDenied ( Exception $ex ) : boolean Checks if an exception that was thrown after running a query represents an 'access denied' error.

Описание методов

getRequiredPrivileges() публичный статический Метод

NOTE: LOAD DATA INFILE & LOCK TABLES privileges are not **required** so they're not checked.
public static getRequiredPrivileges ( ) : array
Результат array

getRequiredPrivilegesPretty() публичный статический Метод

Returns a string description of the database privileges required for Piwik to run.
public static getRequiredPrivilegesPretty ( ) : string
Результат string

validateOwner() публичный Метод

Checks that the DB user entered in the form has the necessary privileges for Piwik to run.
public validateOwner ( )