| 6 | * tree. An additional intellectual property rights grant can be found |
| 7 | * in the file PATENTS. All contributing project authors may |
| 8 | * be found in the AUTHORS file in the root of the source tree. |
| 9 | */ |
| 10 |
| 11 | #include "api/data_channel_interface.h" |
| 12 |
| 13 | #include "rtc_base/checks.h" |
| 14 |
| 15 | namespace webrtc { |
| 16 |
| 17 | bool DataChannelInterface::ordered() const { |
| 18 | return false; |
| 19 | } |
| 20 |
| 21 | uint16_t DataChannelInterface::maxRetransmitTime() const { |
| 22 | return 0; |
| 23 | } |
| 24 |
| 25 | uint16_t DataChannelInterface::maxRetransmits() const { |
| 26 | return 0; |
| 27 | } |
| 28 |
| 29 | absl::optional<int> DataChannelInterface::maxRetransmitsOpt() const { |
| 30 | return absl::nullopt; |
| 31 | } |
| 32 |
| 33 | absl::optional<int> DataChannelInterface::maxPacketLifeTime() const { |
| 34 | return absl::nullopt; |
| 35 | } |
| 36 |
| 37 | std::string DataChannelInterface::protocol() const { |
| 38 | return std::string(); |
| 39 | } |
| 40 |
| 41 | bool DataChannelInterface::negotiated() const { |
| 42 | return false; |
| 43 | } |
| 44 |
| 45 | uint64_t DataChannelInterface::MaxSendQueueSize() { |
| 46 | return 16 * 1024 * 1024; // 16 MiB |
| 47 | } |
| 48 |
| 49 | // TODO(tommi): Remove method once downstream implementations have been removed. |
| 50 | bool DataChannelInterface::Send(const DataBuffer& buffer) { |
| 51 | RTC_DCHECK_NOTREACHED(); |
| 52 | return false; |
| 53 | } |
| 54 |
| 55 | // TODO(tommi): Remove implementation once method is pure virtual. |
| 56 | void DataChannelInterface::SendAsync( |
| 57 | DataBuffer buffer, |
| 58 | absl::AnyInvocable<void(RTCError) &&> on_complete) { |
| 59 | RTC_DCHECK_NOTREACHED(); |
| 60 | } |
| 61 |
| 62 | } // namespace webrtc |
| 63 |