-
Notifications
You must be signed in to change notification settings - Fork 17
Event object
A CTF event.
Event objects are used in the events
property of a
stream object.
Property | Type | Description | Required? | Default value |
---|---|---|---|---|
log-level |
String (predefined log level name) or integer (zero or positive) | Log level of this event | Optional | No log level |
context-type |
Type object or string (alias name) | Type of event context (must be a [[structure type object | Structure type object]]) | Optional |
payload-type |
Type object or string (alias name) | Type of event payload (must be a [[structure type object | Structure type object]]) | Required |
[[$include
|
Including external YAML files]] | String or array of strings | Include base properties from external YAML file(s) | Optional |
All the properties which have a default value can also be set to
null
to force this default value. This is especially useful when
including external YAML files.
Available log level names, for a given event, are defined by the
$log-levels
property of the metadata object
containing it.
Each field of the event context structure type (context-type
property)
corresponds to one parameter
of the generated tracing function (prefixed with ec_
).
Each field of the event payload structure type (payload-type
property)
corresponds to one parameter
of the generated tracing function (prefixed with ep_
). The event
payload structure type must contain at least one field.
Each field name of the context-type
and payload-type
properties must be a
valid C identifier.
log-level: error
context-type:
class: struct
fields:
msg_id: uint16
payload-type:
class: struct
fields:
src:
type: string
dst:
type: string
payload_sz: uint32
Copyright © 2014-2016 Philippe Proulx (project license)