Linking configs, elements and attributes¶
- class Parser.LinkElement.Link(link: Optional[Union[str, Parser.LinkElement.Link]] = None, emphasize: int = 1)[source]¶
The Link utility class is used for creating references to various components of the configuration model. A link could point to 3 different types of places:
A Subconfig; For example:
cores/
An element inside a subconfig; For example:
cores/core_0
A An attribute instacne inside of an element inside of a subconfig; For example:
cores/core_0:core_name
Links can be global or local to a subconfig in which case the subconfig part of a link does not need to be specified. For example if in the context of subconfig
cores
we wanted to point to thecore_name
attribute ofcore_0
we could usecore_0:core_name
. But if we wanted to access the same attribute from a config file other thancores.json
we would need to writecores/core_0:core_name
.