James Kuszmaul | 6439136 | 2021-01-17 11:32:00 -0800 | [diff] [blame^] | 1 | #pragma once |
| 2 | #include <rawrtcdc/data_channel.h> |
| 3 | #include <rawrtcc/code.h> |
| 4 | #include <re.h> |
| 5 | |
| 6 | /** |
| 7 | * Data channel parameters. |
| 8 | */ |
| 9 | struct rawrtc_data_channel_parameters { |
| 10 | char* label; // copied |
| 11 | enum rawrtc_data_channel_type channel_type; |
| 12 | uint32_t reliability_parameter; // contains either max_packet_lifetime or max_retransmit |
| 13 | char* protocol; // copied |
| 14 | bool negotiated; |
| 15 | uint16_t id; |
| 16 | }; |
| 17 | |
| 18 | enum rawrtc_code rawrtc_data_channel_parameters_create_internal( |
| 19 | struct rawrtc_data_channel_parameters** const parametersp, // de-referenced |
| 20 | char* const label, // referenced, nullable |
| 21 | enum rawrtc_data_channel_type const channel_type, |
| 22 | uint32_t const reliability_parameter, |
| 23 | char* const protocol, // referenced, nullable |
| 24 | bool const negotiated, |
| 25 | uint16_t const id); |