| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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_FAILING_HTTP_TRANSACTION_FACTORY_H_ | 5 #ifndef NET_FAILING_HTTP_TRANSACTION_FACTORY_H_ |
| 6 #define NET_FAILING_HTTP_TRANSACTION_FACTORY_H_ | 6 #define NET_FAILING_HTTP_TRANSACTION_FACTORY_H_ |
| 7 | 7 |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "net/base/net_errors.h" | 9 #include "net/base/net_errors.h" |
| 10 #include "net/base/request_priority.h" | 10 #include "net/base/request_priority.h" |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 // started. | 21 // started. |
| 22 class NET_EXPORT FailingHttpTransactionFactory : public HttpTransactionFactory { | 22 class NET_EXPORT FailingHttpTransactionFactory : public HttpTransactionFactory { |
| 23 public: | 23 public: |
| 24 // The caller must guarantee that |session| outlives this object. | 24 // The caller must guarantee that |session| outlives this object. |
| 25 FailingHttpTransactionFactory(HttpNetworkSession* session, Error error); | 25 FailingHttpTransactionFactory(HttpNetworkSession* session, Error error); |
| 26 virtual ~FailingHttpTransactionFactory(); | 26 virtual ~FailingHttpTransactionFactory(); |
| 27 | 27 |
| 28 // HttpTransactionFactory: | 28 // HttpTransactionFactory: |
| 29 virtual int CreateTransaction( | 29 virtual int CreateTransaction( |
| 30 RequestPriority priority, | 30 RequestPriority priority, |
| 31 scoped_ptr<HttpTransaction>* trans) OVERRIDE; | 31 scoped_ptr<HttpTransaction>* trans) override; |
| 32 virtual HttpCache* GetCache() OVERRIDE; | 32 virtual HttpCache* GetCache() override; |
| 33 virtual HttpNetworkSession* GetSession() OVERRIDE; | 33 virtual HttpNetworkSession* GetSession() override; |
| 34 | 34 |
| 35 private: | 35 private: |
| 36 HttpNetworkSession* session_; | 36 HttpNetworkSession* session_; |
| 37 Error error_; | 37 Error error_; |
| 38 }; | 38 }; |
| 39 | 39 |
| 40 } // namespace net | 40 } // namespace net |
| 41 | 41 |
| 42 #endif // NET_FAILING_HTTP_TRANSACTION_FACTORY_H_ | 42 #endif // NET_FAILING_HTTP_TRANSACTION_FACTORY_H_ |
| OLD | NEW |