Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(444)

Side by Side Diff: net/url_request/url_request_throttler_entry_interface.h

Issue 7033036: net: Add NET_API to url_request. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef NET_URL_REQUEST_URL_REQUEST_THROTTLER_ENTRY_INTERFACE_H_ 5 #ifndef NET_URL_REQUEST_URL_REQUEST_THROTTLER_ENTRY_INTERFACE_H_
6 #define NET_URL_REQUEST_URL_REQUEST_THROTTLER_ENTRY_INTERFACE_H_ 6 #define NET_URL_REQUEST_URL_REQUEST_THROTTLER_ENTRY_INTERFACE_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
11 #include "base/time.h" 11 #include "base/time.h"
12 #include "net/base/net_api.h"
12 13
13 namespace net { 14 namespace net {
14 15
15 class URLRequestThrottlerHeaderInterface; 16 class URLRequestThrottlerHeaderInterface;
16 17
17 // Interface provided on entries of the URL request throttler manager. 18 // Interface provided on entries of the URL request throttler manager.
18 class URLRequestThrottlerEntryInterface 19 class NET_API URLRequestThrottlerEntryInterface
19 : public base::RefCountedThreadSafe<URLRequestThrottlerEntryInterface> { 20 : public base::RefCountedThreadSafe<URLRequestThrottlerEntryInterface> {
20 public: 21 public:
21 URLRequestThrottlerEntryInterface() {} 22 URLRequestThrottlerEntryInterface() {}
22 23
23 // Returns true when we have encountered server errors and are doing 24 // Returns true when we have encountered server errors and are doing
24 // exponential back-off. 25 // exponential back-off.
25 // URLRequestHttpJob checks this method prior to every request; it 26 // URLRequestHttpJob checks this method prior to every request; it
26 // cancels requests if this method returns true. 27 // cancels requests if this method returns true.
27 virtual bool IsDuringExponentialBackoff() const = 0; 28 virtual bool IsDuringExponentialBackoff() const = 0;
28 29
(...skipping 28 matching lines...) Expand all
57 virtual ~URLRequestThrottlerEntryInterface() {} 58 virtual ~URLRequestThrottlerEntryInterface() {}
58 59
59 private: 60 private:
60 friend class base::RefCounted<URLRequestThrottlerEntryInterface>; 61 friend class base::RefCounted<URLRequestThrottlerEntryInterface>;
61 DISALLOW_COPY_AND_ASSIGN(URLRequestThrottlerEntryInterface); 62 DISALLOW_COPY_AND_ASSIGN(URLRequestThrottlerEntryInterface);
62 }; 63 };
63 64
64 } // namespace net 65 } // namespace net
65 66
66 #endif // NET_URL_REQUEST_URL_REQUEST_THROTTLER_ENTRY_INTERFACE_H_ 67 #endif // NET_URL_REQUEST_URL_REQUEST_THROTTLER_ENTRY_INTERFACE_H_
OLDNEW
« no previous file with comments | « net/url_request/url_request_throttler_entry.h ('k') | net/url_request/url_request_throttler_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698