protected function buildFactory($factoryClass)
    {
        $factory = $factoryClass::newInstance();
        $factory->setConfig($this->config);
        $factory->validateConfig();

        return $factory;
    }