pub struct ProbeData<'a> {
pub buf: &'a [u8],
pub ext: Option<&'a str>,
}Expand description
Information passed to a content-based [ProbeFn].
buf holds the first few KB of the input — enough to recognise the
magic bytes of any container we know about. ext carries the file
extension as a hint (lowercase, no leading dot); some containers
(raw MP3 with no ID3v2, headerless tracker formats) need it to break
ties with otherwise weak signatures.
Fields§
§buf: &'a [u8]§ext: Option<&'a str>Auto Trait Implementations§
impl<'a> Freeze for ProbeData<'a>
impl<'a> RefUnwindSafe for ProbeData<'a>
impl<'a> Send for ProbeData<'a>
impl<'a> Sync for ProbeData<'a>
impl<'a> Unpin for ProbeData<'a>
impl<'a> UnsafeUnpin for ProbeData<'a>
impl<'a> UnwindSafe for ProbeData<'a>
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