pub struct ExtHeader {
pub identifier: u32,
pub header_length: u32,
pub record_count: u32,
pub records: IndexMap<ExthRecord, Vec<Vec<u8>>>,
}
Expand description
Optional header containing extended information. If the MOBI header indicates that there’s an EXTH header, it follows immediately after the MOBI header.
Fields§
§identifier: u32
§header_length: u32
§record_count: u32
§records: IndexMap<ExthRecord, Vec<Vec<u8>>>
Implementations§
source§impl ExtHeader
impl ExtHeader
sourcepub fn get_record_position(&self, position: u32) -> Option<&Vec<Vec<u8>>>
pub fn get_record_position(&self, position: u32) -> Option<&Vec<Vec<u8>>>
Returns exth record data located at position. This is a low level function intended to use with wrapper get_record, but exposed for convienience.
sourcepub fn get_record(&self, record: ExthRecord) -> Option<&Vec<Vec<u8>>>
pub fn get_record(&self, record: ExthRecord) -> Option<&Vec<Vec<u8>>>
Returns exth record data. This function limits possible queried records to only those commonly available among mobi ebooks.
sourcepub fn raw_records(&self) -> impl Iterator<Item = (&ExthRecord, &Vec<Vec<u8>>)>
pub fn raw_records(&self) -> impl Iterator<Item = (&ExthRecord, &Vec<Vec<u8>>)>
Returns an iterator over all available raw EXTH records.
Trait Implementations§
impl Eq for ExtHeader
impl StructuralEq for ExtHeader
impl StructuralPartialEq for ExtHeader
Auto Trait Implementations§
impl RefUnwindSafe for ExtHeader
impl Send for ExtHeader
impl Sync for ExtHeader
impl Unpin for ExtHeader
impl UnwindSafe for ExtHeader
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.