博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

JSON Study Diagram

Posted on 2009-05-18 14:28  chgBlog  阅读(166)  评论(0)    收藏  举报

This article comes from www.json.org

I Think is userful for everyone to understand and study it.

 

In JSON, they take on these forms:

An object is an unordered set of name/value pairs. An object begins with { (left brace) and ends with } (right brace). Each name is followed by : (colon) and the name/value pairs are separated by , (comma).

An array is an ordered collection of values. An array begins with [ (left bracket) and ends with ] (right bracket). Values are separated by , (comma).

A value can be a string in double quotes, or a number, or true or false or null, or an object or an array. These structures can be nested.

A string is a collection of zero or more Unicode characters, wrapped in double quotes, using backslash escapes. A character is represented as a single character string. A string is very much like a C or Java string.

A number is very much like a C or Java number, except that the octal and hexadecimal formats are not used.