#[non_exhaustive]pub struct BodySection {
pub section: String,
pub origin: Option<u64>,
pub data: Option<Vec<u8>>,
}Expand description
A single fetched body section (RFC 3501 Section 6.4.5).
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.section: StringThe section specification (e.g. "HEADER", "1.2", "TEXT").
origin: Option<u64>Byte offset if this was a partial fetch (<origin.count>).
RFC 9051 Section 7.5.2 widens this from number (u32) to number64 (u64)
to support messages > 4 GiB.
data: Option<Vec<u8>>The raw body data, or None if the server returned NIL.
Trait Implementations§
Source§impl Clone for BodySection
impl Clone for BodySection
Source§fn clone(&self) -> BodySection
fn clone(&self) -> BodySection
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 moreSource§impl Debug for BodySection
impl Debug for BodySection
Source§impl Default for BodySection
impl Default for BodySection
Source§fn default() -> BodySection
fn default() -> BodySection
Returns the “default value” for a type. Read more
Source§impl Hash for BodySection
impl Hash for BodySection
Source§impl PartialEq for BodySection
impl PartialEq for BodySection
impl Eq for BodySection
impl StructuralPartialEq for BodySection
Auto Trait Implementations§
impl Freeze for BodySection
impl RefUnwindSafe for BodySection
impl Send for BodySection
impl Sync for BodySection
impl Unpin for BodySection
impl UnsafeUnpin for BodySection
impl UnwindSafe for BodySection
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