def htmlCreatePushParser(SAX, chunk, size, URI):
    """Create a progressive HTML parser context to build either an
      event flow if the SAX object is not None, or a DOM tree
       otherwise. """
    ret = libxml2mod.htmlCreatePushParser(SAX, chunk, size, URI)
    if ret is None:raise parserError('htmlCreatePushParser() failed')
    return parserCtxt(_obj=ret)