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

Side by Side Diff: webkit/glue/p2p_transport.h

Issue 7888022: Add DISABLE_TCP_TRANSPORT flag in the Transport API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: - Created 9 years, 3 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
« no previous file with comments | « remoting/protocol/pepper_stream_channel.cc ('k') | webkit/glue/p2p_transport.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 WEBKIT_GLUE_P2P_TRANSPORT_H_ 5 #ifndef WEBKIT_GLUE_P2P_TRANSPORT_H_
6 #define WEBKIT_GLUE_P2P_TRANSPORT_H_ 6 #define WEBKIT_GLUE_P2P_TRANSPORT_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/basictypes.h"
12
11 namespace net { 13 namespace net {
12 class Socket; 14 class Socket;
13 } // namespace net 15 } // namespace net
14 16
15 namespace WebKit { 17 namespace WebKit {
16 class WebFrame; 18 class WebFrame;
17 } // namespace WebKit 19 } // namespace WebKit
18 20
19 namespace webkit_glue { 21 namespace webkit_glue {
20 22
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 74
73 // TCP window sizes. Default size is used when set to 0. 75 // TCP window sizes. Default size is used when set to 0.
74 int tcp_receive_window; 76 int tcp_receive_window;
75 int tcp_send_window; 77 int tcp_send_window;
76 78
77 // Disables Neagle's algorithm when set to true. 79 // Disables Neagle's algorithm when set to true.
78 bool tcp_no_delay; 80 bool tcp_no_delay;
79 81
80 // TCP ACK delay. 82 // TCP ACK delay.
81 int tcp_ack_delay_ms; 83 int tcp_ack_delay_ms;
84
85 // Disable TCP-based transport when set to true.
86 bool disable_tcp_transport;
82 }; 87 };
83 88
84 virtual ~P2PTransport() {} 89 virtual ~P2PTransport() {}
85 90
86 // Initialize transport using specified configuration. |web_frame| 91 // Initialize transport using specified configuration. |web_frame|
87 // is used to make HTTP requests to relay servers. Returns true 92 // is used to make HTTP requests to relay servers. Returns true
88 // if initialization succeeded. 93 // if initialization succeeded.
89 virtual bool Init(WebKit::WebFrame* web_frame, 94 virtual bool Init(WebKit::WebFrame* web_frame,
90 const std::string& name, 95 const std::string& name,
91 Protocol protocol, 96 Protocol protocol,
92 const Config& config, 97 const Config& config,
93 EventHandler* event_handler) = 0; 98 EventHandler* event_handler) = 0;
94 99
95 // Add candidate received from the remote peer. Returns false if the 100 // Add candidate received from the remote peer. Returns false if the
96 // provided address is not in a valid format. 101 // provided address is not in a valid format.
97 virtual bool AddRemoteCandidate(const std::string& address) = 0; 102 virtual bool AddRemoteCandidate(const std::string& address) = 0;
98 103
99 // Returns socket interface that can be used to send/receive 104 // Returns socket interface that can be used to send/receive
100 // data. Returned object is owned by the transport. Pending calls on 105 // data. Returned object is owned by the transport. Pending calls on
101 // the socket are canceled when the transport is destroyed. 106 // the socket are canceled when the transport is destroyed.
102 virtual net::Socket* GetChannel() = 0; 107 virtual net::Socket* GetChannel() = 0;
103 }; 108 };
104 109
105 } // namespace webkit_glue 110 } // namespace webkit_glue
106 111
107 #endif // WEBKIT_GLUE_P2P_TRANSPORT_H_ 112 #endif // WEBKIT_GLUE_P2P_TRANSPORT_H_
OLDNEW
« no previous file with comments | « remoting/protocol/pepper_stream_channel.cc ('k') | webkit/glue/p2p_transport.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698