blob: 93d3f7934b6dba03507121caf0dfdedbb39e0cac [file] [log] [blame]
Zach Steine20867f2018-08-02 20:20:151/*
2 * Copyright 2018 The WebRTC Project Authors. All rights reserved.
3 *
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
Steve Anton10542f22019-01-11 17:11:0011#ifndef API_ASYNC_RESOLVER_FACTORY_H_
12#define API_ASYNC_RESOLVER_FACTORY_H_
Zach Steine20867f2018-08-02 20:20:1513
Steve Anton10542f22019-01-11 17:11:0014#include "rtc_base/async_resolver_interface.h"
Zach Steine20867f2018-08-02 20:20:1515
16namespace webrtc {
17
18// An abstract factory for creating AsyncResolverInterfaces. This allows
19// client applications to provide WebRTC with their own mechanism for
20// performing DNS resolution.
21class AsyncResolverFactory {
22 public:
23 AsyncResolverFactory() = default;
24 virtual ~AsyncResolverFactory() = default;
25
Zach Stein6fcdc2f2018-08-23 23:25:5526 // The caller should call Destroy on the returned object to delete it.
Zach Steine20867f2018-08-02 20:20:1527 virtual rtc::AsyncResolverInterface* Create() = 0;
28};
29
30} // namespace webrtc
31
Steve Anton10542f22019-01-11 17:11:0032#endif // API_ASYNC_RESOLVER_FACTORY_H_