session.maxDatagramSize
- 类型:<number>
对等方将接受的最大数据报有效载荷大小(字节)。
这是从对等方的 maxDatagramFrameSize 传输参数中减去 DATAGRAM 帧开销(类型字节和可变长度整数编码)得出的。如果对等方不支持数据报或握手尚未完成,则返回 0。大于该值的数据报将不会被发送。
🌐 The maximum datagram payload size in bytes that the peer will accept.
This is derived from the peer's maxDatagramFrameSize transport
parameter minus the DATAGRAM frame overhead (type byte and variable-length
integer encoding). Returns 0 if the peer does not support datagrams or
if the handshake has not yet completed. Datagrams larger than this value
will not be sent.