OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: [xml-dev] Microsoft FUD on binary XML...

[ Lists Home | Date Index | Thread Index ]

I don't know why people don't also factor in SGML or microparsing as well as potentially
playing a part; For example.

<dataset/27,12/

15 bytes. SGML users commmonly ended up with less than one character per
tag this way, without leaving the text world. In other words, there are other options
(with XML bindings) more terse than XML before you get to binary.

Also, it would interesting to see binary people use Chinese (Japanese or Korean) text
and markup for their test data.  Compressing or packing ASCII is quite different to
compressing or packing UTF-16 Chinese, which has a more random-seeming distribution
of byte values.  It is not dishonest to make the case for binary using data that
is most compressible; but businesses who are looking at compression strategies
for world-wide use need to factor in CJK compressability into their evaluations.

Cheers
Rick Jelliffe

Bob Wyman wrote:
Jeff Lowery wrote:
  
What can be achieved by binary XML that can't 
be similarly achieved using well-known text 
compression algorithms?
    
 
	Let me give a really trivial example that shows some of the
benefits.
	Let's say that you had the following XML: (warning,
instructive but highly contrived example follows...)

<dataset>
 <x>27</x>
 <y>12</y>
</dataset>

There are about 45 bytes there if you count CRLF and the
pretty-printing spaces. Now, a binary encoding that was schema driven
would look at this and might replace the tags with index numbers which
would be stored as bytes. Thus, dataset becomes "1", x becomes "2" and
y becomes "3." The encoder, if it new that the values of x and y were
supposed to be integers might also replace the two character strings
with one byte integers. If the encoding was of the "tag-length-value"
family, it would first write a tag number to the stream, then a length
and then the value. This would give you the following sequence of 6
bytes for the XML above:
1	Dataset Tag
4	length of data included in Dataset
2	"x" tag
27	value of x
3	"y" tag
12	value of y
 
So, you could encode dataset in 3 bytes:
1	Dataset Tag
27	value of x
12	value of y
 





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS