Add new certificateProvider extension API.
[chromium-blink-merge.git] / chrome / browser / devtools / devtools_network_conditions.h
blobe15a5d64611df7702d91036b97012abf78626946
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_DEVTOOLS_DEVTOOLS_NETWORK_CONDITIONS_H_
6 #define CHROME_BROWSER_DEVTOOLS_DEVTOOLS_NETWORK_CONDITIONS_H_
8 #include <string>
9 #include <vector>
11 #include "base/macros.h"
13 class GURL;
15 // DevToolsNetworkConditions holds information about desired network conditions.
16 class DevToolsNetworkConditions {
17 public:
18 DevToolsNetworkConditions();
19 ~DevToolsNetworkConditions();
21 explicit DevToolsNetworkConditions(bool offline);
22 DevToolsNetworkConditions(bool offline,
23 double latency,
24 double download_throughput,
25 double upload_throughput);
27 bool IsThrottling() const;
29 bool offline() const { return offline_; }
30 double latency() const { return latency_; }
31 double download_throughput() const { return download_throughput_; }
32 double upload_throughput() const { return upload_throughput_; }
34 private:
35 const bool offline_;
36 const double latency_;
37 const double download_throughput_;
38 const double upload_throughput_;
40 DISALLOW_COPY_AND_ASSIGN(DevToolsNetworkConditions);
43 #endif // CHROME_BROWSER_DEVTOOLS_DEVTOOLS_NETWORK_CONDITIONS_H_