O'Reilly logo

C++ Reactive Programming by Peter Abraham, Praseed Pai

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The JSON and HTTP protocols

The payload format for invoking web services was once monopolized by the XML format. The SOAP-based services mostly support the XML format. With the advent of REST-based services, developers use JavaScript Object Notation (JSON) as the payload format. The following table shows a comparison between XML and the corresponding JSON object:

XML
JSON
<person>  <firstName>John</firstName>  <lastName>Smith</lastName>  <age>25</age>  <address>    <streetAddress>21 2nd Street</streetAddress>    <city>New York</city>    <state>NY</state>    <postalCode>10021</postalCode>  </address>  <phoneNumber>    <type>home</type>    <number>212 555-1234</number>  </phoneNumber>  <phoneNumber>    <type>fax</type>    <number>646 555-4567</number> </phoneNumber> ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required