Module fuchsia_inspect::reader

source ·
Expand description

§Reading inspect data

Provides an API for reading inspect data from a given [Inspector][Inspector], VMO, byte vectors, etc.

§Concepts

§Diagnostics hierarchy

Represents the inspect VMO as a regular tree of data. The API ensures that this structure always contains the lazy values loaded as well.

§Partial node hierarchy

Represents the inspect VMO as a regular tree of data, but unlike the Diagnostics Hierarchy, it won’t contain the lazy values loaded. An API is provided for converting this to a diagnostics hierarchy (Into<DiagnosticsHierarchy>), but keep in mind that the resulting diagnostics hierarchy won’t contain any of the lazy values.

§Example usage

use fuchsia_inspect::{Inspector, reader};

let inspector = Inspector::default();
// ...
let hierarchy = reader::read(&inspector)?;

Modules§

  • A snapshot represents all the loaded blocks of the VMO in a way that we can reconstruct the implicit tree.

Structs§

  • A hierarchy of nodes representing structured data, such as Inspect or structured log data.
  • A partial node hierarchy represents a node in an inspect tree without the linked (lazy) nodes expanded. Usually a client would prefer to use a DiagnosticsHierarchy to get the full inspect tree.

Enums§

  • Represents the content of a DiagnosticsHierarchy array property: a regular array or a linear/exponential histogram.
  • Format in which the array will be read.
  • Disposition of a Link value.
  • A named property. Each of the fields consists of (name, value).

Traits§

  • Trait implemented by structs that can provide inspect data and their lazy links.

Functions§

  • Reads the given ReadableTree into a DiagnosticsHierarchy. This reads versions 1 and 2 of the Inspect Format.
  • Reads the given ReadableTree into a DiagnosticsHierarchy with Lazy Node timeout. This reads versions 1 and 2 of the Inspect Format.