Skip to Content
RESTful Java Web Services - Third Edition
book

RESTful Java Web Services - Third Edition

by Balachandar Bogunuva Mohanram
November 2017
Intermediate to advanced
420 pages
10h 29m
English
Packt Publishing
Content preview from RESTful Java Web Services - Third Edition

Basic data types available with JSON

While discussing the JSON syntax in the previous section, we glanced at some of the basic data types used in JSON. Let's take a detailed look at each item.

Here is the list of the basic data types available with JSON:

  • Number: This type is used for storing a signed decimal number that may optionally contain a fractional part. Both integer and floating point numbers are represented by using this data type. The following example uses the decimal data type for storing totalWeight:
{"totalWeight": 123.456} 
  • String: This type represents a sequence of zero or more characters. Strings are surrounded with double quotation marks and support a backslash escaping syntax. Here is an example for the string data type: ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

RESTful Java Web Services, Second Edition

RESTful Java Web Services, Second Edition

Jobinesh Purushothaman
Java Web Services

Java Web Services

David A Chappell, Tyler Jewell

Publisher Resources

ISBN: 9781788294041Supplemental Content