def _getMultiElemText(parentElem, elemName, topKey, bottomKey):
    """
    XML parsing helper function to return a 2-level :py:class:`dict` of multiple elements by a specified name, using ``topKey`` as the first key, and ``bottomKey`` as the second key.
    
    :param SubElement parentElem: the :py:class:`XML SubElement <xml.etree.ElementTree.SubElement>` to query.
    :param str elemName: search for XML elements with this tag.
    :param str topKey: filter on those XML elements with this attribute name.
    :param str bottomKey: filter on those XML elements with this attribute name.

    :returns: a two-level :py:class:`dict` consisting of keys given by ``elem.attrib[ topKey ]``, and values given by a dictionary: ``{ bottomKey: elem.attrib[ bottomKey ], 'TEXT' : elem.text }``. In addition, for an element whose attributes are not in ``topKey``, there is a key of ``0`` and value of ``{ bottomKey: elem.attrib[ bottomKey ], 'TEXT' : elem.text }``.
    :rtype: dict
    """
    elems = parentElem.findall(elemName)
    result = {} # 2-level dictionary of items, keyed by topKey and then bottomKey
    if elems is not None:
        for elem in elems:
            if topKey in elem.attrib:
                result[elem.attrib[topKey]] = {bottomKey:elem.attrib[bottomKey], 'TEXT':elem.text}
            else:
                result['0'] = {bottomKey:elem.attrib[bottomKey], 'TEXT':elem.text}
    return result