launch_yaml package

Subpackages

Submodules

Module contents

Package for launch_description_sources.

class launch_yaml.Entity(*args: Any, **kwargs: Any)

Bases: Entity

Single item in the intermediate YAML front_end representation.

assert_entity_completely_parsed()
property children: List[Entity]

Get the Entity’s children.

get_attr(name: str, *, data_type: launch.utilities.type_utils.AllowedTypesType = <class 'str'>, optional: bool = False, can_be_str: bool = True) launch.utilities.type_utils.AllowedValueType | List[Entity] | None

Access an attribute of the entity.

See launch.frontend.Entity.get_attr(). launch_yaml does not apply type coercion, it only checks if the read value is of the correct type.

property parent: Entity | None

Get Entity parent.

property type_name: str

Get Entity type.

class launch_yaml.Parser(*args: Any, **kwargs: Any)

Bases: Parser

YAML parser implementation.

classmethod get_file_extensions() Set[str]

Return the set of file extensions known to this parser.

classmethod load(file: launch.utilities.typing_file_path.FilePath | ~typing.TextIO) -> (<class 'launch_yaml.entity.Entity'>, 'Parser')

Return entity loaded from YAML file.