def iterparse(filelike, encoding=None, handler_class=DrillHandler, xpath=None):
parser = expat.ParserCreate(encoding)<EOL>elem_iter = DrillElementIterator(filelike, parser)<EOL>handler = handler_class(elem_iter, xpath)<EOL>parser.buffer_text = <NUM_LIT:1><EOL>parser.StartElementHandler = handler.start_element<EOL>parser.EndElementHandler = handler.end_element<EOL>parser.CharacterDataHandler = handler.characters<EOL>return elem_iter<EOL>
:param filelike: A file-like object with a ``read`` method
:returns: An iterator yielding :class:`XmlElement` objects