dmi_entity_context

Synopsis

#include <opendmi/entity.h>

dmi_context_t *dmi_entity_context(const dmi_entity_t *entity);

Description

The dmi_entity_context function returns the context a structure belongs to, which holds the data the structure has been decoded from.

Code which is given a structure alone, such as a handler of an extension module, reaches the context through it to raise errors, see dmi_error_raise, and to write messages, see dmi_log.

Parameters

entity

Structure to query.

Return value

Returns the context, or nullptr if entity is nullptr.

Errors

None.