Right now, if an XmlReader is positioned on an empty tag and you call getTextValue() or getContent(), it calls read() as the first thing, advances beyond the empty tag and effectively starts processing its parent returning the text/XML content from that point to its end.
The obvious answer could be "you silly, don't run it on an empty tag" but I'd like to propose a consistent solution.
Right now, if an
XmlReader
is positioned on an empty tag and you callgetTextValue()
orgetContent()
, it callsread()
as the first thing, advances beyond the empty tag and effectively starts processing its parent returning the text/XML content from that point to its end.The obvious answer could be "you silly, don't run it on an empty tag" but I'd like to propose a consistent solution.
Hence this PR :)