Add example listing a files directories

This commit is contained in:
A. Molzer committed 2026-02-07 08:22:34 +01:00
1 parent a0191ed1a7
commit cef21c47fb
3 files changed
+143 -1

No files matched your search

+6 -1
View File
@@ -1538,7 +1538,7 @@ impl<R: Read + Seek> Decoder<R> {
}
/// Get the IFD decoder for our current image IFD.
fn image_ifd(&mut self) -> IfdDecoder<'_> {
pub fn image_ifd(&mut self) -> IfdDecoder<'_> {
IfdDecoder {
inner: tag_reader::TagReader {
decoder: &mut self.value_reader,
@@ -1885,6 +1885,11 @@ impl IfdDecoder<'_> {
pub fn get_tag_ascii_string(&mut self, tag: Tag) -> TiffResult<String> {
self.get_tag(tag)?.into_string()
}
/// Inspect the raw underlying directory.
pub fn directory(&self) -> &Directory {
self.inner.ifd
}
}
impl<'l> IfdDecoder<'l> {