def METHOD_NAME(self, root_hit_elem, query_id, query_seq=None):
    """Parse hit (PRIVATE)."""
    # feed the loop below an empty list so iteration still works
    if root_hit_elem is None:
        root_hit_elem = []
    for hit_elem in root_hit_elem:
        # store the match/location type
        hit_type = re.sub(r"%s(\w+)-match" % self.NS, r"\1", hit_elem.find(".").tag)
        # store the hit id
        signature = hit_elem.find(self.NS + "signature")
        hit_id = signature.attrib["ac"]
        # store xrefs and alt_descs
        xrefs = self._parse_xrefs(signature.find(self.NS + "entry"))
        # parse each hsp
        hsps = list(
            self._parse_hsp(
                hit_elem.find(self.NS + "locations"), query_id, hit_id, query_seq
            )
        )
        # create hit and assign attributes
        hit = Hit(hsps, hit_id)
        setattr(hit, "dbxrefs", xrefs)
        for key, (attr, caster) in _ELEM_HIT.items():
            value = signature.attrib.get(key)
            if value is not None:
                setattr(hit, attr, caster(value))
        # format specific attributes
        hit.attributes["Hit type"] = hit_type
        signature_lib = signature.find(self.NS + "signature-library-release")
        hit.attributes["Target"] = str(signature_lib.attrib.get("library"))
        hit.attributes["Target version"] = str(signature_lib.attrib.get("version"))
        yield hit