Struct libpna::SolidEntry
source · pub struct SolidEntry<T = Vec<u8>> { /* private fields */ }Expand description
A solid mode entry.
Implementations§
source§impl<T> SolidEntry<T>
impl<T> SolidEntry<T>
sourcepub fn header(&self) -> &SolidHeader
pub fn header(&self) -> &SolidHeader
Returns solid mode information header reference.
sourcepub fn extra_chunks(&self) -> &[RawChunk<T>]
pub fn extra_chunks(&self) -> &[RawChunk<T>]
Extra chunks.
source§impl<T: AsRef<[u8]>> SolidEntry<T>
impl<T: AsRef<[u8]>> SolidEntry<T>
sourcepub fn entries(
&self,
password: Option<&str>,
) -> Result<impl Iterator<Item = Result<RegularEntry>> + '_>
pub fn entries( &self, password: Option<&str>, ) -> Result<impl Iterator<Item = Result<RegularEntry>> + '_>
Returns an iterator over the entries in the SolidEntry.
§Example
§Example
use libpna::{Archive, ReadEntry, ReadOptions};
use std::fs;
let file = fs::File::open("foo.pna")?;
let mut archive = Archive::read_header(file)?;
for entry in archive.entries() {
match entry? {
ReadEntry::Solid(solid_entry) => {
for entry in solid_entry.entries(Some("password"))? {
let entry = entry?;
let mut reader = entry.reader(ReadOptions::builder().build());
// fill your code
}
}
ReadEntry::Regular(entry) => {
// fill your code
}
}
}Trait Implementations§
source§impl<T: Clone> Clone for SolidEntry<T>
impl<T: Clone> Clone for SolidEntry<T>
source§fn clone(&self) -> SolidEntry<T>
fn clone(&self) -> SolidEntry<T>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl<T: Debug> Debug for SolidEntry<T>
impl<T: Debug> Debug for SolidEntry<T>
source§impl<'a> From<SolidEntry<&'a [u8]>> for SolidEntry<Vec<u8>>
impl<'a> From<SolidEntry<&'a [u8]>> for SolidEntry<Vec<u8>>
source§fn from(value: SolidEntry<&'a [u8]>) -> Self
fn from(value: SolidEntry<&'a [u8]>) -> Self
Converts to this type from the input type.
source§impl<'a> From<SolidEntry<&'a [u8]>> for SolidEntry<Cow<'a, [u8]>>
impl<'a> From<SolidEntry<&'a [u8]>> for SolidEntry<Cow<'a, [u8]>>
source§fn from(value: SolidEntry<&'a [u8]>) -> Self
fn from(value: SolidEntry<&'a [u8]>) -> Self
Converts to this type from the input type.
source§impl<'a> From<SolidEntry<Cow<'a, [u8]>>> for SolidEntry<Vec<u8>>
impl<'a> From<SolidEntry<Cow<'a, [u8]>>> for SolidEntry<Vec<u8>>
source§impl<'a> From<SolidEntry> for SolidEntry<Cow<'a, [u8]>>
impl<'a> From<SolidEntry> for SolidEntry<Cow<'a, [u8]>>
source§impl<T: Hash> Hash for SolidEntry<T>
impl<T: Hash> Hash for SolidEntry<T>
source§impl<T: Ord> Ord for SolidEntry<T>
impl<T: Ord> Ord for SolidEntry<T>
source§fn cmp(&self, other: &SolidEntry<T>) -> Ordering
fn cmp(&self, other: &SolidEntry<T>) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl<T: PartialEq> PartialEq for SolidEntry<T>
impl<T: PartialEq> PartialEq for SolidEntry<T>
source§impl<T: PartialOrd> PartialOrd for SolidEntry<T>
impl<T: PartialOrd> PartialOrd for SolidEntry<T>
impl<T> Entry for SolidEntry<T>where
SolidEntry<T>: SealedEntryExt,
impl<T: Eq> Eq for SolidEntry<T>
impl<T> StructuralPartialEq for SolidEntry<T>
Auto Trait Implementations§
impl<T> Freeze for SolidEntry<T>
impl<T> RefUnwindSafe for SolidEntry<T>where
T: RefUnwindSafe,
impl<T> Send for SolidEntry<T>where
T: Send,
impl<T> Sync for SolidEntry<T>where
T: Sync,
impl<T> Unpin for SolidEntry<T>where
T: Unpin,
impl<T> UnwindSafe for SolidEntry<T>where
T: UnwindSafe,
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)