OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_EXTENSIONS_API_CAST_CHANNEL_CAST_SOCKET_H_ | 5 #ifndef EXTENSIONS_BROWSER_API_CAST_CHANNEL_CAST_SOCKET_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_API_CAST_CHANNEL_CAST_SOCKET_H_ | 6 #define EXTENSIONS_BROWSER_API_CAST_CHANNEL_CAST_SOCKET_H_ |
7 | 7 |
8 #include <queue> | 8 #include <queue> |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
12 #include "base/callback.h" | 12 #include "base/callback.h" |
13 #include "base/gtest_prod_util.h" | 13 #include "base/gtest_prod_util.h" |
14 #include "base/memory/ref_counted.h" | 14 #include "base/memory/ref_counted.h" |
15 #include "base/memory/weak_ptr.h" | 15 #include "base/memory/weak_ptr.h" |
16 #include "base/threading/thread_checker.h" | 16 #include "base/threading/thread_checker.h" |
17 #include "chrome/common/extensions/api/cast_channel.h" | |
18 #include "extensions/browser/api/api_resource.h" | 17 #include "extensions/browser/api/api_resource.h" |
19 #include "extensions/browser/api/api_resource_manager.h" | 18 #include "extensions/browser/api/api_resource_manager.h" |
| 19 #include "extensions/common/api/cast_channel.h" |
20 #include "net/base/completion_callback.h" | 20 #include "net/base/completion_callback.h" |
21 #include "net/base/io_buffer.h" | 21 #include "net/base/io_buffer.h" |
22 #include "net/base/ip_endpoint.h" | 22 #include "net/base/ip_endpoint.h" |
23 #include "net/base/net_log.h" | 23 #include "net/base/net_log.h" |
24 | 24 |
25 namespace net { | 25 namespace net { |
26 class AddressList; | 26 class AddressList; |
27 class CertVerifier; | 27 class CertVerifier; |
28 class SSLClientSocket; | 28 class SSLClientSocket; |
29 class StreamSocket; | 29 class StreamSocket; |
30 class TCPClientSocket; | 30 class TCPClientSocket; |
31 class TransportSecurityState; | 31 class TransportSecurityState; |
32 } | 32 } |
33 | 33 |
34 namespace extensions { | 34 namespace extensions { |
35 namespace api { | 35 namespace core_api { |
36 namespace cast_channel { | 36 namespace cast_channel { |
37 | 37 |
38 class CastMessage; | 38 class CastMessage; |
39 | 39 |
40 // This class implements a channel between Chrome and a Cast device using a TCP | 40 // This class implements a channel between Chrome and a Cast device using a TCP |
41 // socket with SSL. The channel may authenticate that the receiver is a genuine | 41 // socket with SSL. The channel may authenticate that the receiver is a genuine |
42 // Cast device. All CastSocket objects must be used only on the IO thread. | 42 // Cast device. All CastSocket objects must be used only on the IO thread. |
43 // | 43 // |
44 // NOTE: Not called "CastChannel" to reduce confusion with the generated API | 44 // NOTE: Not called "CastChannel" to reduce confusion with the generated API |
45 // code. | 45 // code. |
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
343 | 343 |
344 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestFullSecureConnectionFlowAsync); | 344 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestFullSecureConnectionFlowAsync); |
345 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestRead); | 345 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestRead); |
346 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestReadHeaderParseError); | 346 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestReadHeaderParseError); |
347 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestReadMany); | 347 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestReadMany); |
348 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestWriteErrorLargeMessage); | 348 FRIEND_TEST_ALL_PREFIXES(CastSocketTest, TestWriteErrorLargeMessage); |
349 DISALLOW_COPY_AND_ASSIGN(CastSocket); | 349 DISALLOW_COPY_AND_ASSIGN(CastSocket); |
350 }; | 350 }; |
351 | 351 |
352 } // namespace cast_channel | 352 } // namespace cast_channel |
353 } // namespace api | 353 } // namespace core_api |
354 } // namespace extensions | 354 } // namespace extensions |
355 | 355 |
356 #endif // CHROME_BROWSER_EXTENSIONS_API_CAST_CHANNEL_CAST_SOCKET_H_ | 356 #endif // EXTENSIONS_BROWSER_API_CAST_CHANNEL_CAST_SOCKET_H_ |
OLD | NEW |