class connection_parameter_factory

Helper class to generate Doctrine DBAL configuration.

Methods

static array
get_configuration(string $driver, string|null $host = null, string|null $user = null, string|null $password = null, string|null $name = null, string|null $port = null)

Returns configuration options for Doctrine DBAL.

Details

at line 38
static array get_configuration(string $driver, string|null $host = null, string|null $user = null, string|null $password = null, string|null $name = null, string|null $port = null)

Returns configuration options for Doctrine DBAL.

Parameters

string $driver

Driver name.

string|null $host

Hostname.

string|null $user

Username.

string|null $password

Password.

string|null $name

Database name.

string|null $port

Database port.

Return Value

array

Doctrine DBAL connection parameters.

Exceptions

InvalidArgumentException

If a required parameter is empty or null.