class Requirements

Class Requirements

Constants

REQUIREMENT_OK

Requirement severity -- Requirement successfully met.

REQUIREMENT_WARNING

Requirement severity -- Warning condition; proceed but flag warning.

REQUIREMENT_ERROR

Requirement severity -- Error condition; abort installation.

Properties

protected array $system_checks
protected $database_checks

Methods

array
checkAll(array $config)

Run all requirements tests.

array
checkSystem(array $file_paths)

Check system requirements are met, such as sufficient memory, necessary file paths are writable and required php extensions are available.

array
checkDatabase(array $db_config)

Check database connection, database version and other database requirements are met.

object
connect($db_config)

Generates a mysql connection

array
checkMemory()

Check configured php Memory.

float
getPHPMemory()

Get Configured PHP memory.

array
checkServerVariables()

No description

array
checkJsonEncodeExists()

No description

array
checkMultibyteExists()

CHeck that PHP Multibyte functions are enabled.

array
checkMysqlConnectExists()

No description

array
checkMysqlConnection(array $db_config)

No description

array
checkMysqlVersion(array $db_config)

No description

array
checkMysqlInnodb(array $db_config)

No description

array
checkMysqlTempTables(array $db_config)

No description

array
checkMysqlTrigger($db_config)

No description

array
checkMySQLAutoIncrementIncrementOne(array $db_config)

No description

array
checkMysqlThreadStack($db_config)

No description

array
checkMysqlLockTables($db_config)

No description

array
checkFilepathIsWritable($file_paths)

No description

array
checkMysqlUtf8mb4($db_config)

No description

Details

at line 60
array checkAll(array $config)

Run all requirements tests.

Parameters

array $config An array with two keys: - file_paths - db_config

Return Value

array An array of check summaries. Each array contains the keys 'title', 'severity', and 'details'.

at line 75
array checkSystem(array $file_paths)

Check system requirements are met, such as sufficient memory, necessary file paths are writable and required php extensions are available.

Parameters

array $file_paths An array of file paths that will be checked to confirm they are writable.

Return Value

array

at line 99
array checkDatabase(array $db_config)

Check database connection, database version and other database requirements are met.

Parameters

array $db_config An array with keys: - host (with optional port specified eg. localhost:12345) - database (name of database to select) - username - password

Return Value

array

at line 115
protected object connect($db_config)

Generates a mysql connection

Parameters

$db_config array

Return Value

object mysqli connection

at line 131
array checkMemory()

Check configured php Memory.

Return Value

array

at line 162
protected float getPHPMemory()

Get Configured PHP memory.

Return Value

float

at line 183
array checkServerVariables()

Return Value

array

at line 210
array checkJsonEncodeExists()

Return Value

array

at line 228
array checkMultibyteExists()

CHeck that PHP Multibyte functions are enabled.

Return Value

array

at line 245
array checkMysqlConnectExists()

Return Value

array

at line 264
array checkMysqlConnection(array $db_config)

Parameters

array $db_config

Return Value

array

at line 293
array checkMysqlVersion(array $db_config)

Parameters

array $db_config

Return Value

array

at line 322
array checkMysqlInnodb(array $db_config)

Parameters

array $db_config

Return Value

array

at line 357
array checkMysqlTempTables(array $db_config)

Parameters

array $db_config

Return Value

array

at line 393
array checkMysqlTrigger($db_config)

Parameters

$db_config

Return Value

array

at line 438
array checkMySQLAutoIncrementIncrementOne(array $db_config)

Parameters

array $db_config

Return Value

array

at line 472
array checkMysqlThreadStack($db_config)

Parameters

$db_config

Return Value

array

at line 516
array checkMysqlLockTables($db_config)

Parameters

$db_config

Return Value

array

at line 568
array checkFilepathIsWritable($file_paths)

Parameters

$file_paths

Return Value

array

at line 595
array checkMysqlUtf8mb4($db_config)

Parameters

$db_config

Return Value

array