| 1649 | return self.target.end_ns(prefix or '') |
| 1650 | |
| 1651 | def _start(self, tag, attr_list): |
| 1652 | # Handler for expat's StartElementHandler. Since ordered_attributes |
| 1653 | # is set, the attributes are reported as a list of alternating |
| 1654 | # attribute name,value. |
| 1655 | fixname = self._fixname |
| 1656 | tag = fixname(tag) |
| 1657 | attrib = {} |
| 1658 | if attr_list: |
| 1659 | for i in range(0, len(attr_list), 2): |
| 1660 | attrib[fixname(attr_list[i])] = attr_list[i+1] |
| 1661 | return self.target.start(tag, attrib) |
| 1662 | |
| 1663 | def _end(self, tag): |
| 1664 | return self.target.end(self._fixname(tag)) |