Skip to main content

Module pod

Module pod 

Source
Expand description

#[repr(C)] POD types shared by the FFI (by layout) and the pipe wire (by explicit little-endian serialization in fmf-proto).

The const blocks pin every size and offset at cargo check time — the same pins fmf-ffi’s contract_tests re-assert at run time as an independent tripwire, and gen-contract radiates to C# [FieldOffset] values.

Structs§

FmfBlob
Engine-allocated UTF-8 JSON payload (stats, query traces); release with fmf_blob_free.
FmfEvent
POD event payload — FFI callback argument and pipe event-push body (32 bytes). volume is the zero-padded UTF-8 drive label (“C:”).
FmfPage
FFI page: one contiguous engine-allocated block (row array + string blob). Pointers, so FFI-only — the pipe sends rows and blob inline.
FmfQueryOptions
Query options — 20 bytes, no padding, LE on the wire. Field values are the crate::options enums as u32.
FmfRow
48-byte result row, no internal padding. Offsets index into the page’s trailing string blob (WTF-8). Mirrored by C# LayoutKind.Explicit.
FmfVolumeStatus
FFI volume status. state is crate::options::VolumeState as u32.
FrameHeader
16-byte little-endian pipe frame header. to_bytes/from_bytes are pure byte conversions — the MAX_PAYLOAD_LEN policy lives in fmf-proto’s decode_header/read_frame.