pub struct ExecutableCategorizer;Expand description
Categorizer for executable binaries. Detects ELF / PE / Mach-O magic and routes x86_64 / aarch64 architectures to BCJ-x86 / BCJ-ARM64 composite codecs.
Trait Implementations§
Source§impl FileCategorizer for ExecutableCategorizer
impl FileCategorizer for ExecutableCategorizer
Source§fn categories(&self) -> &'static [&'static str]
fn categories(&self) -> &'static [&'static str]
Categories this categorizer can emit. Used for diagnostic
dumps; does not affect dispatch.
Source§fn first_byte_hint(&self) -> Option<&'static [u8]>
fn first_byte_hint(&self) -> Option<&'static [u8]>
The set of first bytes that this categorizer can possibly
match. The registry uses this to skip categorizers without
a function call when
data[0] isn’t in the set. Read moreSource§fn categorize(&self, _path: &Path, data: &[u8]) -> Option<Categorization>
fn categorize(&self, _path: &Path, data: &[u8]) -> Option<Categorization>
Categorize a file by its path and full contents. Read more
Auto Trait Implementations§
impl Freeze for ExecutableCategorizer
impl RefUnwindSafe for ExecutableCategorizer
impl Send for ExecutableCategorizer
impl Sync for ExecutableCategorizer
impl Unpin for ExecutableCategorizer
impl UnsafeUnpin for ExecutableCategorizer
impl UnwindSafe for ExecutableCategorizer
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more