ElasticSearch.withUri constructor

ElasticSearch.withUri(
  1. Uri uri,
  2. {ElasticSearchCredentials credentials,
  3. HttpClient httpClient,
  4. bool autoCreateIndex = true}
)

Implementation

ElasticSearch.withUri(
  this.uri, {
  ElasticSearchCredentials credentials,
  HttpClient httpClient,
  this.autoCreateIndex = true,
})  : _credentials = credentials,
      httpClient = httpClient ?? HttpClient() {
  if (credentials != null) {
    credentials.prepareHttpClient(this, httpClient);
  }
  ArgumentError.checkNotNull(autoCreateIndex, 'autoCreateIndex');
}