protected virtual void Dispose(bool disposing) { if (disposing && _search != null) { _search.Dispose(); _search = null; } }
protected virtual void Dispose(bool disposing) { if (disposing) { _searchIndexClient?.Dispose(); _searchServiceClient?.Dispose(); } }
public void Initialize() { // add for Azure Seach SockeException under .net 4.5.2 System.Net.ServicePointManager.SecurityProtocol |= System.Net.SecurityProtocolType.Tls12; if (_searchClient != null) { _searchClient.Dispose(); } if (_indexClient != null) { _indexClient.Dispose(); } // 検索クライアント初期化 _searchClient = new SearchServiceClient(SearchServiceName, new SearchCredentials(SearchServiceApiKey)); _indexClient = _searchClient.Indexes.GetClient(SearchIndex); }
protected virtual void Dispose(bool disposing) { if (!disposedValue) { if (disposing) { _client.Dispose(); } disposedValue = true; } }
public void Dispose() { foreach (var client in _clients.Values) { client.Dispose(); } foreach (var indexer in _indexers) { indexer.Dispose(); } if (createdSearchServiceClient) { _client?.Dispose(); } }
protected virtual void Dispose(bool disposing) { if (_disposed) { return; } if (disposing) { _serviceClient.Dispose(); _serviceClient = null; _searchClient.Dispose(); _searchClient = null; _indexClient.Dispose(); _indexClient = null; } _disposed = true; }
public void Dispose() { if (_disposed) { return; } foreach (var indexer in _indexers) { indexer.Dispose(); } foreach (var client in _clients.Values) { client.Dispose(); } if (createdSearchServiceClient) { _client?.Dispose(); } _disposed = true; }
public void Dispose() { indexClient.Dispose(); serviceClient.Dispose(); }
public void Dispose() { _serviceClient.Dispose(); }
public void Dispose() { _client?.Dispose(); }