pub enum Header {
Target(u32),
Context(u32),
}Variants§
Target(u32)
When this audio is sent by the client to the server, this is set to the target of the audio data. This target is a number in the range [0, 2^{32} - 1], where 0 means “normal talking”, 2^{5} - 1 means “server loopback” and all other targets are understood as shout/whisper targets that have previously been registered via a VoiceTarget message (via TCP).
Context(u32)
When this audio is sent by the server to the client, this indicates the context in which the audio has been sent. 0: Normal speech 1: Shout to channel 2: Whisper to user 3: Received via channel listener
Implementations§
Source§impl Header
impl Header
Sourcepub fn merge(
field: &mut Option<Header>,
tag: u32,
wire_type: WireType,
buf: &mut impl Buf,
ctx: DecodeContext,
) -> Result<(), DecodeError>
pub fn merge( field: &mut Option<Header>, tag: u32, wire_type: WireType, buf: &mut impl Buf, ctx: DecodeContext, ) -> Result<(), DecodeError>
Decodes an instance of the message from a buffer, and merges it into self.
Sourcepub fn encoded_len(&self) -> usize
pub fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Trait Implementations§
impl Copy for Header
impl StructuralPartialEq for Header
Auto Trait Implementations§
impl Freeze for Header
impl RefUnwindSafe for Header
impl Send for Header
impl Sync for Header
impl Unpin for Header
impl UnwindSafe for Header
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