Skip to main content

Module inheritance

Module inheritance 

Source
Expand description

base_name resolver with cycle detection.

DDS-XML 1.0 allows several building blocks (QoS profiles §7.3.2.4.2, domain §7.3.4.4.2, domain participant §7.3.5.4.3) a base_name-attribute- based inheritance. The spec requires the base definition to come before the inheriting definition — naive implementations can nevertheless create cycles across library boundaries.

This module implements a generic inheritance resolution with DAG checking. The resolution routine is parameterized over the item type (e.g. QoS profile, domain, participant) and the base_name lookup function.

Constants§

MAX_INHERITANCE_DEPTH
Maximum inheritance depth (DoS cap).

Functions§

resolve_chain
Resolves a base_name-chain starting at name and returns the chain in base-first order, i.e. [grandparent, parent, name].