Struct webrtc_sctp::stack::queue::OutgoingDataQueue[][src]

pub struct OutgoingDataQueue { /* fields omitted */ }

An outgoing data queue suitable for use as a send-buffer (data chunks enqueued to be transmitted) and a sent-buffer (data chunks that have been transmitted, but have not yet been acknowledged). This is currently implemented as a BTreeSet instead of a Vec to maintain ordering even when retransmissions requirements might otherwise cause re-queueing in an arbitrary order. (Receiving multiple SACKs from the peer with different gap ack blocks could lead to retransmissions in any conceivable order.)

This implementation should work, but it seems very inefficient. It should definitely be reassessed in the future to see if there is a more efficient strategy.

Methods

impl OutgoingDataQueue
[src]

Create a new OutgoingDataQueue

Return the total number of bytes used by all the data chunk buffers contained in this queue.

When we receive a cumulative TSN acknowledgement, all chunks with this TSN and earlier should be dropped. This is true not only for the sent-buffer, but also for the send-buffer since some of its items may be retransmissions.

Transfer data chunks from one queue to another, returning the number of payload bytes transferred.

Transfer all data chunks from one queue to another, returning the total number of payload bytes transferred.

Transfer a range of data chunks from one queue to another, returning the total number of payload bytes transferred.

Auto Trait Implementations