labapi.util.extract#

Utilities for extracting data from lxml.etree.Element objects.

Includes flattening nested extractor dictionaries, converting strings to booleans, and a general-purpose XML extraction function.

Module Attributes

EtreeExtractorDict

Type alias for a dictionary used to define the structure and extraction logic for lxml.etree.Element objects.

Functions

extract_etree(_etree, schema)

Extract data from an lxml.etree.Element using a format dictionary.

to_bool(s)

Convert a string representation to a boolean value.