1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
//! Shared object header messages (`H5O_shared_t`).
//!
//! A message whose header flags carry [`MSG_FLAG_SHARED`] does not hold its
//! own body. What follows the message header is a *reference* to where the
//! body really lives — another object header, or the file's shared-message
//! heap — and decoding those bytes as if they were the body is not a decode
//! failure but a wrong answer: the first byte of a v2 shared message is the
//! version `2`, which a datatype decoder reads as version 0, class 2.
//!
//! This is how a dataset built on a committed (named) datatype stores its
//! type: one `H5O_SHARE_TYPE_COMMITTED` reference to the object header of the
//! datatype it shares.
//!
//! The reference itself is decoded by
//! [`SharedMessagePointer`](crate::format::sohm::SharedMessagePointer), which
//! the object-header reader resolves through for both storage types; this
//! module is only the flag that says a body is one.
/// `H5O_MSG_FLAG_SHARED` — the message body is a reference, not the message.
/// Defined with the rest of the message-envelope flags and re-exported here,
/// where the readers that consult it look for it.
pub use MSG_FLAG_SHARED;
/// How an object header stores one message, as its flags byte says.
///
/// The three cases are what `H5O__debug_real` prints as the message's flags
/// and, for a shared one, what `H5O__shared_debug` prints beneath it
/// (H5Odbg.c:409-455, H5Oshared.c:682-706).