equal
deleted
inserted
replaced
12 public function register() { |
12 public function register() { |
13 $this->app->bind( |
13 $this->app->bind( |
14 'CorpusParole\Libraries\Sparql\SparqlClient', |
14 'CorpusParole\Libraries\Sparql\SparqlClient', |
15 function($app) { |
15 function($app) { |
16 $httpClient = $app->make('GuzzleHttp\Client', [[ 'base_uri' => config('corpusparole.rdf4j_query_url'), 'http_errors' => false]]); |
16 $httpClient = $app->make('GuzzleHttp\Client', [[ 'base_uri' => config('corpusparole.rdf4j_query_url'), 'http_errors' => false]]); |
17 $sparqlClient = $app->make('EasyRdf\Sparql\Client', [config('corpusparole.rdf4j_query_url'), config('corpusparole.rdf4j_update_url')]); |
17 // we create another guzzle client to avoid interference with the base_uri parameter |
|
18 $sparqlClient = $app->make('CorpusParole\Libraries\Sparql\GuzzleSparqlClient', [$app['Guzzle'], config('corpusparole.rdf4j_query_url'), config('corpusparole.rdf4j_update_url')]); |
18 return new SparqlClient($httpClient, $sparqlClient); |
19 return new SparqlClient($httpClient, $sparqlClient); |
19 } |
20 } |
20 ); |
21 ); |
21 } |
22 } |
22 } |
23 } |