Struct webrtc_mdns::message::builder::Builder
source · pub struct Builder {
pub msg: Option<Vec<u8>>,
pub section: Section,
pub header: HeaderInternal,
pub start: usize,
pub compression: Option<HashMap<String, usize>>,
}
Fields§
§msg: Option<Vec<u8>>
§section: Section
§header: HeaderInternal
§start: usize
§compression: Option<HashMap<String, usize>>
Implementations§
source§impl Builder
impl Builder
pub fn new(h: &Header) -> Self
pub fn enable_compression(&mut self)
pub fn start_questions(&mut self) -> Result<(), Error>
pub fn start_answers(&mut self) -> Result<(), Error>
pub fn start_additionals(&mut self) -> Result<(), Error>
pub fn add_question(&mut self, q: &Question) -> Result<(), Error>
pub fn add_resource(&mut self, r: &mut Resource) -> Result<(), Error>
pub fn finish(&mut self) -> Result<Vec<u8>, Error>
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
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