pub struct SenderReport { /* private fields */ }Expand description
Sender report.
Implementations§
Source§impl SenderReport
impl SenderReport
Sourcepub fn decode(packet: &RtcpPacket) -> Result<Self, InvalidInput>
pub fn decode(packet: &RtcpPacket) -> Result<Self, InvalidInput>
Decode sender report.
Sourcepub fn encode(&self) -> RtcpPacket
pub fn encode(&self) -> RtcpPacket
Encode the sender report.
Sourcepub fn sender_ssrc(&self) -> u32
pub fn sender_ssrc(&self) -> u32
Get SSRC identifier of the sender.
Sourcepub fn with_sender_ssrc(self, ssrc: u32) -> Self
pub fn with_sender_ssrc(self, ssrc: u32) -> Self
Set the SSRC identifier of the sender.
Sourcepub fn ntp_timestamp(&self) -> u64
pub fn ntp_timestamp(&self) -> u64
Get NTP timestamp as a 32.32 fixed point number.
Sourcepub fn with_ntp_timestamp(self, timestamp: u64) -> Self
pub fn with_ntp_timestamp(self, timestamp: u64) -> Self
Set the NTP timestamp as a 32.32. fixed point number.
Sourcepub fn rtp_timestamp(&self) -> u32
pub fn rtp_timestamp(&self) -> u32
Get RTP timestamp.
Sourcepub fn with_rtp_timestamp(self, timestamp: u32) -> Self
pub fn with_rtp_timestamp(self, timestamp: u32) -> Self
Set the RTP timestamp.
Sourcepub fn packet_count(&self) -> u32
pub fn packet_count(&self) -> u32
Get packet count.
Sourcepub fn with_packet_count(self, count: u32) -> Self
pub fn with_packet_count(self, count: u32) -> Self
Set the packet count.
Sourcepub fn octet_count(&self) -> u32
pub fn octet_count(&self) -> u32
Get octet count.
Sourcepub fn with_octet_count(self, count: u32) -> Self
pub fn with_octet_count(self, count: u32) -> Self
Set the octet count.
Sourcepub fn report_blocks(&self) -> &[ReportBlock]
pub fn report_blocks(&self) -> &[ReportBlock]
Get report blocks.
Sourcepub fn with_report_blocks<T>(self, blocks: T) -> Self
pub fn with_report_blocks<T>(self, blocks: T) -> Self
Set the report blocks.
§Panics
The method will panic if the number of report blocks is greater than 31.
Trait Implementations§
Source§impl Clone for SenderReport
impl Clone for SenderReport
Source§fn clone(&self) -> SenderReport
fn clone(&self) -> SenderReport
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for SenderReport
impl RefUnwindSafe for SenderReport
impl Send for SenderReport
impl Sync for SenderReport
impl Unpin for SenderReport
impl UnwindSafe for SenderReport
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more