pub struct MmapParser { /* private fields */ }Expand description
Memory-mapped file parser for large files
Uses OS-level memory mapping for efficient access to large files without loading entire file into memory.
§Examples
use aion_context::parser::MmapParser;
let parser = MmapParser::open("large_file.aion")?;
let header = parser.header();
println!("File ID: {}", header.file_id);Implementations§
Source§impl MmapParser
impl MmapParser
Sourcepub const fn header(&self) -> &FileHeader
pub const fn header(&self) -> &FileHeader
Get reference to file header
Sourcepub fn encrypted_rules_bytes(&self) -> Result<&[u8]>
pub fn encrypted_rules_bytes(&self) -> Result<&[u8]>
Get encrypted rules section
Sourcepub fn version_chain_bytes(&self) -> Result<&[u8]>
pub fn version_chain_bytes(&self) -> Result<&[u8]>
Get version chain section
Sourcepub fn signatures_bytes(&self) -> Result<&[u8]>
pub fn signatures_bytes(&self) -> Result<&[u8]>
Get signatures section
Sourcepub fn audit_trail_bytes(&self) -> Result<&[u8]>
pub fn audit_trail_bytes(&self) -> Result<&[u8]>
Get audit trail section
Sourcepub fn string_table_bytes(&self) -> Result<&[u8]>
pub fn string_table_bytes(&self) -> Result<&[u8]>
Get string table section
Sourcepub fn integrity_hash(&self) -> Result<&[u8; 32]>
pub fn integrity_hash(&self) -> Result<&[u8; 32]>
Get file integrity hash
Sourcepub fn verify_integrity(&self) -> Result<()>
pub fn verify_integrity(&self) -> Result<()>
Verify file integrity
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MmapParser
impl RefUnwindSafe for MmapParser
impl Send for MmapParser
impl Sync for MmapParser
impl Unpin for MmapParser
impl UnsafeUnpin for MmapParser
impl UnwindSafe for MmapParser
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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