Skip to content

Configuration object

Philippe Proulx edited this page Apr 6, 2016 · 3 revisions

The top-level configuration object of the YAML configuration file.

Properties

Property Type Description Required? Default value
version String Minimum required version of barectf (set to '2.1') Required N/A
prefix String Prefix to be used for function names, file names, etc. Optional barectf_
metadata Metadata object Trace metadata Required N/A

The prefix property must be set to a valid C identifier. It can be overridden by the barectf command-line tool's --prefix option.

Example

version: '2.1'
prefix: axx_
metadata:
  type-aliases:
    uint16:
      class: int
      size: 16
  trace:
    byte-order: le
  streams:
    my_stream:
      packet-context-type:
        class: struct
        fields:
          packet_size: uint16
          content_size: uint16
      events:
        my_event:
          payload-type:
            class: struct
            fields:
              a:
                class: int
                size: 8