[email protected] | 5461d9d | 2010-07-31 23:10:07 | [diff] [blame^] | 1 | // Copyright (c) 2010 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. | ||||
[email protected] | 0da3fea3 | 2008-12-17 23:08:24 | [diff] [blame] | 4 | |
5 | #ifndef NET_FTP_FTP_TRANSACTION_FACTORY_H_ | ||||
6 | #define NET_FTP_FTP_TRANSACTION_FACTORY_H_ | ||||
[email protected] | 32b76ef | 2010-07-26 23:08:24 | [diff] [blame] | 7 | #pragma once |
[email protected] | 0da3fea3 | 2008-12-17 23:08:24 | [diff] [blame] | 8 | |
9 | namespace net { | ||||
10 | |||||
[email protected] | 0da3fea3 | 2008-12-17 23:08:24 | [diff] [blame] | 11 | class FtpTransaction; |
12 | |||||
13 | // An interface to a class that can create FtpTransaction objects. | ||||
14 | class FtpTransactionFactory { | ||||
15 | public: | ||||
16 | virtual ~FtpTransactionFactory() {} | ||||
17 | |||||
18 | // Creates a FtpTransaction object. | ||||
19 | virtual FtpTransaction* CreateTransaction() = 0; | ||||
20 | |||||
[email protected] | 0da3fea3 | 2008-12-17 23:08:24 | [diff] [blame] | 21 | // Suspends the creation of new transactions. If |suspend| is false, creation |
22 | // of new transactions is resumed. | ||||
23 | virtual void Suspend(bool suspend) = 0; | ||||
24 | }; | ||||
25 | |||||
26 | } // namespace net | ||||
27 | |||||
28 | #endif // NET_FTP_FTP_TRANSACTION_FACTORY_H_ |