protected function buildDatabase(array $options)
    {
        return (new Database())
            ->setPort($options['db-port'])
            ->setUser($options['db-user'])
            ->setPassword($options['db-pass'])
            ->setDatabase($options['db-name'])
            ->setHostname($options['db-host'])
            ->setProtocol($options['db-protocol']);
    }
protected function buildDatabase(array $options)
    {
        return (new Database())
            ->setPort($options['db-port'])
            ->setUser($options['db-user'])
            ->setPassword($options['db-pass'])
            ->setDatabase($options['db-name'])
            ->setHostname($options['db-host'])
            ->setProtocol($options['db-protocol']);
    }
protected function buildDatabase ( array $ options ) { return ( new Database ( ) ) -> setPort ( $ options [ 'db-port' ] ) -> setUser ( $ options [ 'db-user' ] ) -> setPassword ( $ options [ 'db-pass' ] ) -> setDatabase ( $ options [ 'db-name' ] ) -> setHostname ( $ options [ 'db-host' ] ) -> setProtocol ( $ options [ 'db-protocol' ] ) ; }
Build database object based on options.

@param array $options
An array of options.

@return Database
Build database object based on options .