src/SmartFactory/DatabaseWorkers/MSSQL_DBWorker.php
public function init($parameters)
    {
        if (!empty($parameters["db_server"])) {
            $this->db_server = $parameters["db_server"];
        }
        if (!empty($parameters["db_name"])) {
            $this->db_name = $parameters["db_name"];
        }
        if (!empty($parameters["db_user"])) {
            $this->db_user = $parameters["db_user"];
        }
        if (!empty($parameters["db_password"])) {
            $this->db_password = $parameters["db_password"];
        }
        
        return true;
    }
public function init($parameters)
    {
        if (!empty($parameters["db_server"])) {
            $this->db_server = $parameters["db_server"];
        }
        if (!empty($parameters["db_name"])) {
            $this->db_name = $parameters["db_name"];
        }
        if (!empty($parameters["db_user"])) {
            $this->db_user = $parameters["db_user"];
        }
        if (!empty($parameters["db_password"])) {
            $this->db_password = $parameters["db_password"];
        }
        
        return true;
    }
public function init ( $ parameters ) { if ( ! empty ( $ parameters [ "db_server" ] ) ) { $ this -> db_server = $ parameters [ "db_server" ] ; } if ( ! empty ( $ parameters [ "db_name" ] ) ) { $ this -> db_name = $ parameters [ "db_name" ] ; } if ( ! empty ( $ parameters [ "db_user" ] ) ) { $ this -> db_user = $ parameters [ "db_user" ] ; } if ( ! empty ( $ parameters [ "db_password" ] ) ) { $ this -> db_password = $ parameters [ "db_password" ] ; } return true ; }
Initializes the dbworker with connection paramters.

@param array $parameters
Connection settings as an associative array in the form key => value:

- $parameters["db_server"] - server address.

- $parameters["db_name"] - database name.

- $parameters["db_user"] - user name.

- $parameters["db_password"] - user password.

@return boolean
Returns true upon successful initialization, otherwise false.

@author Oleg Schildt
Initializes the dbworker with connection paramters .