Struct webrtc_data::data_channel::DataChannel [−][src]
pub struct DataChannel {
pub config: Config,
// some fields omitted
}
Expand description
DataChannel represents a data channel
Fields
config: Config
Implementations
Dial opens a data channels over SCTP
Accept is used to accept incoming data channels over SCTP
Client opens a data channel over an SCTP stream
Server accepts a data channel over an SCTP stream
Read reads a packet of len(p) bytes as binary data
ReadDataChannel reads a packet of len(p) bytes
MessagesSent returns the number of messages sent
MessagesReceived returns the number of messages received
BytesSent returns the number of bytes sent
BytesReceived returns the number of bytes received
StreamIdentifier returns the Stream identifier associated to the stream.
Write writes len(p) bytes from p as binary data
WriteDataChannel writes len(p) bytes from p
Close closes the DataChannel and the underlying SCTP stream.
BufferedAmount returns the number of bytes of data currently queued to be sent over this stream.
BufferedAmountLowThreshold returns the number of bytes of buffered outgoing data that is considered “low.” Defaults to 0.
SetBufferedAmountLowThreshold is used to update the threshold. See BufferedAmountLowThreshold().
OnBufferedAmountLow sets the callback handler which would be called when the number of bytes of outgoing data buffered is lower than the threshold.
Trait Implementations
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl !RefUnwindSafe for DataChannel
impl Send for DataChannel
impl Sync for DataChannel
impl Unpin for DataChannel
impl !UnwindSafe for DataChannel
Blanket Implementations
Mutably borrows from an owned value. Read more