blob: 0d1c9af811c412d778d99434fa4d1ca0f5807bf6 [file] [log] [blame]
// Copyright 2018 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.
module network.mojom;
import "url/mojom/url.mojom";
import "services/proxy_resolver/public/mojom/proxy_resolver.mojom";
// Interface for getting the result of a proxy lookup from a NetworkContext.
// Not to be confused with ProxyResolverRequestClient, which is the interface
// between the ProxyResolver service, which executes PAC scripts, and the
// NetworkService.
// Closing the ProxyLookUpClient pipe before the request is complete will cancel
// the proxy lookup.
interface ProxyLookupClient {
// Called with the results of a proxy lookup when it is complete. Invoked only
// once per proxy lookup. |proxy_info| is null if the lookup failed, or if the
// NetworkContext was destroyed. If the lookup failed, |net_error| will
// contain a non-zero code describing the cause of the failure (see
// //net/base/net_error_list.h).
OnProxyLookupComplete(int32 net_error,
proxy_resolver.mojom.ProxyInfo? proxy_info);