tree: a41e0e72f87fc00d2c6b997f659567fbfa66a139 [path history] [tgz]
  1. forwarder/
  2. fuchsia.examples.metadata/
  3. retriever/
  4. sender/
  5. test/
  6. BUILD.gn
  7. fuchsia.examples.metadata.bind
  8. README.md
examples/drivers/metadata/README.md

Driver Metadata Examples

Here are examples of how to send, retrieve, and forward metadata between drivers using the //sdk/lib/driver/metadata library.

Defining Metadata

The fuchsia.examples.metadata FIDL library is an example of how to define metadata.

Sending Metadata

The sender driver is an example of how a driver can send metadata to its child nodes.

Retrieving Metadata

The retriever driver is an example of how a driver can retrieve metadata from parent node.

Forward Metadata

The forwarder driver is an example of how a driver can forward metadata from its parent node to its child nodes.

Testing

Include the tests to your build by appending --with-test //examples/drivers/metadata:tests to your fx set command. For example:

$ fx set core.x64 --with-test //examples/drivers/metadata:tests
$ fx build

Run unit tests with the command:

$ fx test metadata_example_test