|
The author addresses the question of wire transfer differences between JSON and XML adequately but fails to address the marshalling/unmarshalling speed aka serialization cost. JSON is native Javascript and can be converted to javascript objects 10s to 100s of times faster than XML and can be is produced on the server with at minimum the same speed as XML. ( if you are using DOM methods instead of strings on the server json is faster ).
Another misnomer is that JSON is Ruby. While the rails platform obviously popularized it, it neither invented JSON nor is JSON the native data serialization for Ruby. It to uses a parser just as does everybody else. The closest thing to JSON I've actually seen is Python which isn't even mentioned here.
E4X is a nice and simple method of dealing with XML in javascript, and it would be great minus the fact that it can't be used anywhere. The tutorial is useful but the author should stick the tutorial and avoid the editorializing.
|