src/Graviton/ProxyBundle/Controller/ProxyController.php
private function registerProxySources($apiPrefix = '')
    {
        foreach (array_keys($this->proxySourceConfiguration) as $source) {
            foreach ($this->proxySourceConfiguration[$source] as $config) {
                if ($apiPrefix == $config['prefix']) {
                    $this->apiLoader->setOption($config);
                    return;
                }
            }
        }

        $e = new NotFoundException('No such thirdparty API.');
        $e->setResponse(Response::create());
        throw $e;
    }
private function registerProxySources($apiPrefix = '')
    {
        foreach (array_keys($this->proxySourceConfiguration) as $source) {
            foreach ($this->proxySourceConfiguration[$source] as $config) {
                if ($apiPrefix == $config['prefix']) {
                    $this->apiLoader->setOption($config);
                    return;
                }
            }
        }

        $e = new NotFoundException('No such thirdparty API.');
        $e->setResponse(Response::create());
        throw $e;
    }
private function registerProxySources ( $ apiPrefix = '' ) { foreach ( array_keys ( $ this -> proxySourceConfiguration ) as $ source ) { foreach ( $ this -> proxySourceConfiguration [ $ source ] as $ config ) { if ( $ apiPrefix == $ config [ 'prefix' ] ) { $ this -> apiLoader -> setOption ( $ config ) ; return ; } } } $ e = new NotFoundException ( 'No such thirdparty API.' ) ; $ e -> setResponse ( Response :: create ( ) ) ; throw $ e ; }
Registers configured external services to be proxied.

@param string $apiPrefix The prefix of the API

@return void
Registers configured external services to be proxied .