public function setup(array $parameters)
	{
		$parameters = $this->prepareParameters($parameters);

		// Make sure, that 'driver' parameter is handled first.
		if ( isset($parameters['driver']) ) {
			$this->setDriver($parameters['driver']);
			unset($parameters['driver']);
		}

		foreach ( $parameters as $name => $value ) {
			$method = 'set' . ucfirst($name);

			if ( !method_exists($this, $method) ) {
				throw new \InvalidArgumentException('Unable to set unknown parameter "' . $name . '"');
			}

			$this->$method($value);
		}

		return $this;
	}