public function toArray()
    {
        $raw = $this->dsn->toArray();
        $allKeys = array_unique(array_merge(static::$mandatoryKeys, array_keys($raw)));
        $return = [];

        foreach ($allKeys as $key) {
            if (isset($this->keyMap[$key])) {
                $key = $this->keyMap[$key];
                if (!$key) {
                    continue;
                }
            }

            $val = $this->$key;
            if ($val !== null) {
                $return[$key] = $val;
            }
        }

        return $return;
    }
public function toArray()
    {
        $raw = $this->dsn->toArray();
        $allKeys = array_unique(array_merge(static::$mandatoryKeys, array_keys($raw)));
        $return = [];

        foreach ($allKeys as $key) {
            if (isset($this->keyMap[$key])) {
                $key = $this->keyMap[$key];
                if (!$key) {
                    continue;
                }
            }

            $val = $this->$key;
            if ($val !== null) {
                $return[$key] = $val;
            }
        }

        return $return;
    }
public function toArray ( ) { $ raw = $ this -> dsn -> toArray ( ) ; $ allKeys = array_unique ( array_merge ( static :: $ mandatoryKeys , array_keys ( $ raw ) ) ) ; $ return = [ ] ; foreach ( $ allKeys as $ key ) { if ( isset ( $ this -> keyMap [ $ key ] ) ) { $ key = $ this -> keyMap [ $ key ] ; if ( ! $ key ) { continue ; } } $ val = $ this -> $ key ; if ( $ val !== null ) { $ return [ $ key ] = $ val ; } } return $ return ; }
Return the array representation of this dsn

@return array
Return the array representation of this dsn