Called with each complete top-level stanza as a DOM Element.
Called when the closing </stream:stream> tag is received.
Called once the opening <stream:stream …> header is seen, with its
attributes (most importantly id). The header never closes until the
stream ends, so this fires as soon as its start tag is complete.
Called on any XML parse error. The stream should be considered dead.