Struct mobi::headers::MobiHeader
source · pub struct MobiHeader {Show 34 fields
pub identifier: u32,
pub header_length: u32,
pub mobi_type: MobiType,
pub text_encoding: TextEncoding,
pub id: u32,
pub gen_version: u32,
pub ortho_index: u32,
pub inflect_index: u32,
pub index_names: u32,
pub index_keys: u32,
pub extra_indices: [u32; 6],
pub first_non_book_index: u32,
pub name_offset: u32,
pub name_length: u32,
pub locale: u8,
pub language_code: Language,
pub input_language: u32,
pub output_language: u32,
pub format_version: u32,
pub first_image_index: u32,
pub first_huff_record: u32,
pub huff_record_count: u32,
pub huff_table_offset: u32,
pub huff_table_length: u32,
pub exth_flags: u32,
pub drm_offset: u32,
pub drm_count: u32,
pub drm_size: u32,
pub drm_flags: u32,
pub first_content_record: u16,
pub last_content_record: u16,
pub fcis_record: u32,
pub flis_record: u32,
pub first_index_record: u32,
/* private fields */
}
Expand description
Strcture that holds Mobi header information
Fields§
§identifier: u32
§header_length: u32
§mobi_type: MobiType
§text_encoding: TextEncoding
§id: u32
§gen_version: u32
§ortho_index: u32
§inflect_index: u32
§index_names: u32
§index_keys: u32
§extra_indices: [u32; 6]
§first_non_book_index: u32
§name_offset: u32
§name_length: u32
§locale: u8
§language_code: Language
§input_language: u32
§output_language: u32
§format_version: u32
§first_image_index: u32
§first_huff_record: u32
§huff_record_count: u32
§huff_table_offset: u32
§huff_table_length: u32
§exth_flags: u32
§drm_offset: u32
§drm_count: u32
§drm_size: u32
§drm_flags: u32
§first_content_record: u16
§last_content_record: u16
§fcis_record: u32
§flis_record: u32
§first_index_record: u32
Implementations§
source§impl MobiHeader
impl MobiHeader
sourcepub fn has_exth_header(&self) -> bool
pub fn has_exth_header(&self) -> bool
Checks if there is a Exth Header and changes the parameter
pub fn text_encoding(&self) -> TextEncoding
pub fn language(&self) -> Language
Trait Implementations§
source§impl Debug for MobiHeader
impl Debug for MobiHeader
source§impl Default for MobiHeader
impl Default for MobiHeader
source§impl PartialEq<MobiHeader> for MobiHeader
impl PartialEq<MobiHeader> for MobiHeader
source§fn eq(&self, other: &MobiHeader) -> bool
fn eq(&self, other: &MobiHeader) -> bool
impl Eq for MobiHeader
impl StructuralEq for MobiHeader
impl StructuralPartialEq for MobiHeader
Auto Trait Implementations§
impl RefUnwindSafe for MobiHeader
impl Send for MobiHeader
impl Sync for MobiHeader
impl Unpin for MobiHeader
impl UnwindSafe for MobiHeader
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.