Dear ladies and sirs.
I have a stream which contains some XML. The XML may either be encoded using binary XML writer (for instance obtained from XmlDictionaryWriter.CreateBinaryWriter
) or non binary XML writer (like as in XmlWriter.Create
).
I wish to know which reader to use - the one from XmlDictionaryReader.CreateBinaryReader
or the one from XmlReader.Create
. Of course, I can assume that the XML is non binary and then try and fallback to binary. This is what I do today. But I do not like this approach. I wonder if there is an API, which can guide me in the first place which reader to select.
Thanks.