OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
173 // longer part of the session negotiation. | 173 // longer part of the session negotiation. |
174 void SetSendSsrc(uint32_t send_ssrc); | 174 void SetSendSsrc(uint32_t send_ssrc); |
175 // Set the SSRC this channel should use to receive data from the | 175 // Set the SSRC this channel should use to receive data from the |
176 // underlying data engine. | 176 // underlying data engine. |
177 void SetReceiveSsrc(uint32_t receive_ssrc); | 177 void SetReceiveSsrc(uint32_t receive_ssrc); |
178 | 178 |
179 cricket::DataChannelType data_channel_type() const { | 179 cricket::DataChannelType data_channel_type() const { |
180 return data_channel_type_; | 180 return data_channel_type_; |
181 } | 181 } |
182 | 182 |
| 183 // Emitted when state transitions to kOpen. |
| 184 sigslot::signal1<DataChannel*> SignalOpened; |
183 // Emitted when state transitions to kClosed. | 185 // Emitted when state transitions to kClosed. |
184 // In the case of SCTP channels, this signal can be used to tell when the | 186 // In the case of SCTP channels, this signal can be used to tell when the |
185 // channel's sid is free. | 187 // channel's sid is free. |
186 sigslot::signal1<DataChannel*> SignalClosed; | 188 sigslot::signal1<DataChannel*> SignalClosed; |
187 | 189 |
188 protected: | 190 protected: |
189 DataChannel(DataChannelProviderInterface* client, | 191 DataChannel(DataChannelProviderInterface* client, |
190 cricket::DataChannelType dct, | 192 cricket::DataChannelType dct, |
191 const std::string& label); | 193 const std::string& label); |
192 virtual ~DataChannel(); | 194 virtual ~DataChannel(); |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
287 PROXY_CONSTMETHOD0(uint32_t, messages_received) | 289 PROXY_CONSTMETHOD0(uint32_t, messages_received) |
288 PROXY_CONSTMETHOD0(uint64_t, bytes_received) | 290 PROXY_CONSTMETHOD0(uint64_t, bytes_received) |
289 PROXY_CONSTMETHOD0(uint64_t, buffered_amount) | 291 PROXY_CONSTMETHOD0(uint64_t, buffered_amount) |
290 PROXY_METHOD0(void, Close) | 292 PROXY_METHOD0(void, Close) |
291 PROXY_METHOD1(bool, Send, const DataBuffer&) | 293 PROXY_METHOD1(bool, Send, const DataBuffer&) |
292 END_SIGNALING_PROXY() | 294 END_SIGNALING_PROXY() |
293 | 295 |
294 } // namespace webrtc | 296 } // namespace webrtc |
295 | 297 |
296 #endif // WEBRTC_API_DATACHANNEL_H_ | 298 #endif // WEBRTC_API_DATACHANNEL_H_ |
OLD | NEW |