Phalcon\Acl\Adapter\Database::__construct PHP Метод

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

Class constructor.
public __construct ( array $options )
$options array Adapter config
    public function __construct(array $options)
    {
        if (!isset($options['db']) || !$options['db'] instanceof DbAdapter) {
            throw new Exception('Parameter "db" is required and it must be an instance of Phalcon\\Acl\\AdapterInterface');
        }
        $this->connection = $options['db'];
        foreach (['roles', 'resources', 'resourcesAccesses', 'accessList', 'rolesInherits'] as $table) {
            if (!isset($options[$table]) || empty($options[$table]) || !is_string($options[$table])) {
                throw new Exception("Parameter '{$table}' is required and it must be a non empty string");
            }
            $this->{$table} = $this->connection->escapeIdentifier($options[$table]);
        }
    }