inspect::ComponentInspector
#include <component.h>
ComponentInspector is an instance of an Inspector that serves its Inspect data via the fuchsia.inspect.Tree protocol.
Summary
Example:
``` #include
int main() { using inspect::ComponentInspector;
async::Loop loop(&kAsyncLoopConfigAttachToCurrentThread); auto* diser = loop.diser(); auto inspector = ComponentInspector(diser, {});
inspector.root().RecordInt("val1", 1);
inspector.Health().Ok();
loop.Run(); return 0; } ```
Constructors and Destructors | |
---|---|
ComponentInspector(component::OutgoingDirectory & outgoing_directory, async_diser_t *diser, Inspector inspector, TreeHandlerSettings settings) Construct a ComponentInspector and host it on the given outgoing directory. | |
ComponentInspector(ComponentInspector &&) |
Public functions | |
---|---|
Health() | Gets the NodeHealth for this component. |
inspector() const | const Inspector & Get the wrapped Inspector. |
inspector() | |
operator=(ComponentInspector &&)=default | |
root() | Node & Get the Inspector's root node. |
Public functions
ComponentInspector
ComponentInspector( component::OutgoingDirectory & outgoing_directory, async_diser_t *diser, Inspector inspector, TreeHandlerSettings settings )
Construct a ComponentInspector and host it on the given outgoing directory.
Note that it is the caller's responsibility to ensure the outgoing directory is served.
ComponentInspector
ComponentInspector( ComponentInspector && )=default
inspector
Inspector & inspector()
operator=
ComponentInspector & operator=( ComponentInspector && )=default