public function AcquiaSearchV3ApiClient::__construct in Acquia Connector 8
AcquiaSearchV3ApiClient constructor.
Parameters
string $host: Search V3 API host.
string $api_key: Search V3 API key.
\GuzzleHttp\ClientInterface $http_client: Http client.
\Drupal\Core\Cache\CacheBackendInterface $cache: Cache.
File
- acquia_search/
src/ AcquiaSearchV3ApiClient.php, line 71
Class
- AcquiaSearchV3ApiClient
- Search v3 API Client. (Deprecated, use Acquia Search Solr Module instead)
Namespace
Drupal\acquia_searchCode
public function __construct($host, $api_key, ClientInterface $http_client, CacheBackendInterface $cache) {
$this->searchV3Host = $host;
$this->searchV3ApiKey = $api_key;
$this->httpClient = $http_client;
$this->headers = [
'Content-Type' => 'application/json',
'Accept' => 'application/json',
];
$this->cache = $cache;
}