Binary Formats & I/O - Guides
Recipe-style walk-throughs for the Binary Formats & I/O topic - readers (and, for Bodu.IO.Compound and Bodu.IO.Biff, writers) for legacy binary container and document formats. The packages form a strictly layered stack: general-purpose container readers at the bottom (Bodu.IO.Compound and Bodu.IO.Pst), a record codec in the middle (Bodu.IO.Biff), and narrower format readers built on top.
Bodu.IO.Compound reads the OLE2 / Compound File Binary (CFB) envelope - the structured-storage "file system in a file" used by legacy Microsoft Office documents - and exposes the embedded named streams with no application-format knowledge. Bodu.IO.Biff is a low-level codec for the Excel Binary Interchange File Format (BIFF5 and BIFF8) record streams found inside legacy .xls workbooks - the substrate beneath Bodu.Formats.Excel.Binary, in the same relation Bodu.IO.Pst has to Bodu.Formats.Outlook.Pst. Bodu.Formats.Excel.Binary builds on both to surface raw worksheet cell values from BIFF5 and BIFF8 .xls workbooks, and Bodu.Formats.Outlook.Msg builds on the container to open .msg messages. Bodu.IO.Pst reads the second container in the topic - the Outlook personal-folders (PST) node database - and Bodu.Formats.Outlook.Pst builds on it to open a .pst mail store in the same Bodu.Formats.Outlook MAPI value model.
Bodu.IO.Compound guides
The CFB container reader and writer - the storage hierarchy, the stream cursor, editing and authoring, and the OLE property sets.
Overview
The full guide index for Bodu.IO.Compound - namespace map, the storage-hierarchy mental model, and which guide covers each concern.
Reading compound files
Open a file, probe the signature, walk the storage hierarchy with the enumerate and TryOpen surfaces, and read a named stream's bytes.
Buffered vs streaming access
The buffered flag, the CompoundStream cursor, AsMemory vs chunked Read, and bounding memory for large files.
Reading property sets
The SummaryInformation and DocumentSummaryInformation metadata streams, the raw OlePropertySet, and the TryGet* convenience methods.
Office format nuances
How the legacy Office documents (.xls, .doc, .ppt, .msg) lay out their named streams inside the CFB envelope, and the quirks to expect when reading them.
Bodu.IO.Biff guides
The BIFF5 and BIFF8 record codec beneath the .xls reader - writing a workbook stream record by record, and reading one in blocks.
Overview
The full guide index for Bodu.IO.Biff - how the reader and writer work, the namespace map, and which guide covers each concern.
Authoring a workbook stream
Assemble the globals and sheet substreams, patch the BOUNDSHEET offsets, write a shared string table across CONTINUE records, and store the result in a compound file.
Reading a stream a block at a time
Carry BiffReaderState and BytesConsumed from block to block over any stream, keeping the shared string table whole.
Bodu.Formats.Excel.Binary guides
The BIFF5 and BIFF8 .xls reader built on Bodu.IO.Compound and Bodu.IO.Biff surfaces raw worksheet cell values - strings, numbers, booleans, and errors - without formula evaluation, styling, or higher-level interpretation.
Overview
The full guide index for Bodu.Formats.Excel.Binary - the layered BIFF-on-compound-file model, the namespace map, and which guide covers each concern.
Reading workbooks
Open an .xls from a path or stream, list the sheets and used ranges, control stream ownership and optional metadata work, and read document properties.
Cell values and dates
The ExcelCell kinds and value projections, a formula cell's cached result, date-format detection, serial-date conversion, and A1 references.
Streaming vs materialized
The forward-only ExcelWorksheetReader versus the randomly addressable ExcelWorksheet - when to reach for each, and how to bound allocation.
Bodu.IO.Pst guides
The read-only container layer for Outlook personal-folders files (Unicode and ANSI): the node database, the property-context and table-context views with wire-typed values, and the validation levels. No MAPI semantics; the .pst mail-store reader below builds on it.
Overview
The full guide index for Bodu.IO.Pst - how a PST file is a B-tree-indexed database of nodes, the namespace map, and which guide covers each concern.
Reading nodes and tables
Open a file, walk the node B-tree, and read a node's property context and table context.
Streaming and validation
Stream large payloads, the decoded-block cache, and the strict, compatible, and minimal validation levels.
Bodu.Formats.Outlook guides
The Outlook format readers - the shared MAPI value model in Bodu.Formats.Outlook, the read-only .msg reader Bodu.Formats.Outlook.Msg built on Bodu.IO.Compound, and the read-only .pst mail-store reader Bodu.Formats.Outlook.Pst built on Bodu.IO.Pst.
Overview
The full guide index for the Outlook readers - how a .msg file sits inside the CFB container and a .pst store inside the PST node database, the namespace map, and which guide covers each concern.
Reading .msg files
Open a message from a path or stream, the scalar and body conveniences, recipients, attachments, and nested messages.
Reading .pst mail stores
Open a mail store, walk the folder hierarchy, stream its messages, and read their recipients, attachments, and embedded messages.
Properties and named properties
The raw property surface, typed accessors, tags and wire types, and resolving named properties.
Reader options and resource limits
The options both readers take, the limits that bound a crafted file, and omitting unresolvable values instead of failing.
Start here
- Topic overview - the layered container-vs-format split and package selection on the docs side.
- Topic concepts - container, storage, stream, sector chain, BIFF record.
- Reading compound files - the core open → navigate → read recipe that every other use builds on.
- Buffered vs streaming access - once the file is too large to hold whole, or you need to control the source's lifetime.
- Reading property sets - when you want the authored document metadata rather than the format payload.
Where to go next
- Binary Formats & I/O overview - the topic landing page on the docs side.
- Binary Formats & I/O concepts - the cross-package vocabulary.
- Member introductions: Bodu.IO.Compound · Bodu.IO.Biff · Bodu.Formats.Excel.Binary · Bodu.IO.Pst · Bodu.Formats.Outlook.
- Complete guide indexes (this page shows the highlights; each index lists every guide for its package): Bodu.IO.Compound · Bodu.Formats.Excel.Binary · Bodu.IO.Pst · Bodu.Formats.Outlook.
- API reference: Bodu.IO.Compound · Bodu.IO.Biff · Bodu.Formats.Excel · Bodu.IO.Pst · Bodu.Formats.Outlook.