src/RocknRoot/StrayFw/Database/Postgres/Database.php
public function getDsn(array $info) : string
    {
        $dsn = 'pgsql:host=';
        $dsn .= (isset($info['host']) === true ? $info['host'] : 'localhost') . ';';
        if (isset($info['port']) === true) {
            $dsn .= 'port=' . $info['port'] . ';';
        }
        $dsn .= 'dbname=' . $info['name'] . ';';

        return $dsn;
    }
public function getDsn(array $info) : string
    {
        $dsn = 'pgsql:host=';
        $dsn .= (isset($info['host']) === true ? $info['host'] : 'localhost') . ';';
        if (isset($info['port']) === true) {
            $dsn .= 'port=' . $info['port'] . ';';
        }
        $dsn .= 'dbname=' . $info['name'] . ';';

        return $dsn;
    }
Get DSN string for PDO according to specified info.

@param  array  $info database info
@return string DSN string