private function loadAdapter($adapterName, $configName, array $adapterConfig, ContainerBuilder $container)
    {
        if (isset($adapterConfig['service'])) {
            // Custom adapter service.
            $container->setAlias($adapterName, Utility::cleanServiceName($adapterConfig['service']));
            return $this;
        }

        // Built-In Adapter
        switch ($adapterConfig['type']) {
            case 'jsonapiorg':
                $definition = $this->createJsonApiAdapter($configName, $container);
                break;
            default:
                throw new \RuntimeException(sprintf('The adapter type "%s" is currently not supported.', $adapterConfig['type']));
        }
        $container->setDefinition($adapterName, $definition);
        return $this;

    }
private function loadAdapter($adapterName, $configName, array $adapterConfig, ContainerBuilder $container)
    {
        if (isset($adapterConfig['service'])) {
            // Custom adapter service.
            $container->setAlias($adapterName, Utility::cleanServiceName($adapterConfig['service']));
            return $this;
        }

        // Built-In Adapter
        switch ($adapterConfig['type']) {
            case 'jsonapiorg':
                $definition = $this->createJsonApiAdapter($configName, $container);
                break;
            default:
                throw new \RuntimeException(sprintf('The adapter type "%s" is currently not supported.', $adapterConfig['type']));
        }
        $container->setDefinition($adapterName, $definition);
        return $this;

    }
private function loadAdapter ( $ adapterName , $ configName , array $ adapterConfig , ContainerBuilder $ container ) { if ( isset ( $ adapterConfig [ 'service' ] ) ) { // Custom adapter service. $ container -> setAlias ( $ adapterName , Utility :: cleanServiceName ( $ adapterConfig [ 'service' ] ) ) ; return $ this ; } // Built-In Adapter switch ( $ adapterConfig [ 'type' ] ) { case 'jsonapiorg' : $ definition = $ this -> createJsonApiAdapter ( $ configName , $ container ) ; break ; default : throw new \ RuntimeException ( sprintf ( 'The adapter type "%s" is currently not supported.' , $ adapterConfig [ 'type' ] ) ) ; } $ container -> setDefinition ( $ adapterName , $ definition ) ; return $ this ; }
Loads the Adapter service based on the adapter config.

@param   string              $adapterName
@param   string              $configName
@param   array               $adapterConfig
@param   ContainerBuilder    $container
@return  self
Loads the Adapter service based on the adapter config .