| Index: components/data_reduction_proxy/content/browser/data_reduction_proxy_host_impl.h
|
| diff --git a/components/data_reduction_proxy/content/browser/data_reduction_proxy_host_impl.h b/components/data_reduction_proxy/content/browser/data_reduction_proxy_host_impl.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..19b2a334c6060860c85b102581736ace14a82e98
|
| --- /dev/null
|
| +++ b/components/data_reduction_proxy/content/browser/data_reduction_proxy_host_impl.h
|
| @@ -0,0 +1,51 @@
|
| +// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef COMPONENTS_DATA_REDUCTION_PROXY_CONTENT_BROWSER_DATA_REDUCTION_PROXY_HOST_IMPL_H_
|
| +#define COMPONENTS_DATA_REDUCTION_PROXY_CONTENT_BROWSER_DATA_REDUCTION_PROXY_HOST_IMPL_H_
|
| +
|
| +#include "base/macros.h"
|
| +#include "components/data_reduction_proxy/content/common/data_reduction_proxy.mojom.h"
|
| +#include "content/public/browser/render_process_host_observer.h"
|
| +#include "mojo/public/cpp/bindings/binding_set.h"
|
| +
|
| +namespace net {
|
| +class HostPortPair;
|
| +}
|
| +
|
| +namespace data_reduction_proxy {
|
| +
|
| +class DataReductionProxyConfig;
|
| +
|
| +class DataReductionProxyHostImpl : public mojom::DataReductionProxyHost,
|
| + public content::RenderProcessHostObserver {
|
| + public:
|
| + // |config| may be null.
|
| + DataReductionProxyHostImpl(DataReductionProxyConfig* config,
|
| + content::RenderProcessHost* host);
|
| +
|
| + ~DataReductionProxyHostImpl() override;
|
| +
|
| + void BindRequest(mojom::DataReductionProxyHostRequest request);
|
| +
|
| + // mojom::DataReductionProxyHost methods:
|
| + void IsDataReductionProxy(
|
| + const net::HostPortPair& proxy_server,
|
| + const IsDataReductionProxyCallback& callback) override;
|
| +
|
| + // content::RenderProcessHostObserver methods:
|
| + void RenderProcessHostDestroyed(content::RenderProcessHost* host) override;
|
| +
|
| + private:
|
| + // Must outlive |this|. May be null.
|
| + DataReductionProxyConfig* config_;
|
| +
|
| + mojo::BindingSet<mojom::DataReductionProxyHost> bindings_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(DataReductionProxyHostImpl);
|
| +};
|
| +
|
| +} // namespace data_reduction_proxy
|
| +
|
| +#endif // COMPONENTS_DATA_REDUCTION_PROXY_CONTENT_BROWSER_DATA_REDUCTION_PROXY_HOST_IMPL_H_
|
|
|