Java EE notebook
  • Introduction
  • /web-customer-tracker
  • Web Service
  • AOP
  • Web Server2(Spring REST)
  • Security
  • Json
  • Web Server VS Application Server VS Web Containers
  • different between Servlet & JSP2
  • DI
  • 0
  • 1annotation inversion of control, bean scope
  • 2 annotation dependency injection
  • 3 annotation bean scope, java code config
  • 4 Spring MVC
  • rest web services
  • Spring-Hibernate0
  • Spring-Hibernate1
  • @ManyToMany
  • spring mvc work flow
  • Spring Security
  • JWT
  • @Autowired
  • Jersey REST Service
  • Spring Bean
Powered by GitBook
On this page
  • 1. JSON Syntax Rules
  • 2. JSON values
  • 3.Jackson(API) Jackson Library

Was this helpful?

Json

1. JSON Syntax Rules

JSON syntax is derived from JavaScript object notation syntax:

  • Data is in name/value pairs

  • Data is separated by commas

  • Curly braces hold objects

  • Square brackets hold arrays

The JSON format is almost identical to JavaScript objects.

In JSON, _keys _must be strings, written with double quotes:

In JavaScript, keys can be strings, numbers, or identifier names:

2. JSON values

in JSON, values must be one of the following data types:

  1. a string

  2. a number

  3. an object(JSON object)

  4. an array

  5. a boolean

  6. null

in JavaScript values can be all of the above, plus any other valid JavaScript expression, including:

  1. a function

  2. a date

  3. undefined

3.Jackson(API) Jackson Library

Jackson is a high-performance JSON processor for Java. It provides many ways of working including simple POJO converted to/from JSON for simple cases. Jackson provides a set of annotations for mapping too.

PreviousSecurityNextWeb Server VS Application Server VS Web Containers

Last updated 5 years ago

Was this helpful?