Supercharge Your Innovation With Domain-Expert AI Agents!

Analysis and generation method and system of json object of any level

A technology for generating systems and objects, applied in memory systems, program control design, instruments, etc., to achieve the effect of saving development and maintenance labor costs, easy-to-understand code, and simplifying the development process

Active Publication Date: 2015-02-04
北京思特奇信息技术股份有限公司
View PDF7 Cites 9 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] The technical problem to be solved by the present invention is to provide an externally unified method to support the analysis and generation of any json object at any level in view of the shortcomings of the cumbersome process of the prior art.

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Analysis and generation method and system of json object of any level
  • Analysis and generation method and system of json object of any level

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0045] The principles and features of the present invention are described below in conjunction with the accompanying drawings, and the examples given are only used to explain the present invention, and are not intended to limit the scope of the present invention.

[0046] Such as figure 1 As shown, it is a method for parsing and generating JSON objects at any level according to the present invention, which specifically includes the following steps:

[0047] Step 1: define an object array, each object in the object array is a description of a node in json;

[0048] Step 2: Define the hierarchy in the overall json to get a handle;

[0049] Step 3: Select an object array and a handle as the basis, analyze a handle, and obtain each node name and node type corresponding to the handle;

[0050] Step 4: Encapsulate multiple nodes corresponding to the above node names into objects and put them into the object array sequentially;

[0051] Step 5: Obtain an ordered array;

[0052] S...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention relates to an analysis and generation method and system of a json object of any level. The method comprises the following steps of step 1: defining an object number set, wherein each object in the object number set is used for describing one node of json; step 2: defining the level in the json to obtain a handle; step 3: selecting the object number set and one handle as basis and adopting a lexPath method to analyze to obtain an ordered number set; step 4: judging whether the ordered number set has a corresponding relation with a node needing to be operated or not; if so, executing the step 5; otherwise, executing the step 3; step 5: obtaining the type of the node needing to be operated and calling a corresponding api application program programming interface in the json according to the type of the node to finish an analysis or generation function. According to the analysis and generation method and system of the json object of any level, a generated development flow for analyzing the json is simplified so that a code is more popular and easy to understand; the development cost and the manual maintenance cost are saved.

Description

technical field [0001] The invention relates to a method and system for parsing and generating JSON objects at any level, and belongs to the field of software technology. Background technique [0002] With the development of the software industry, communication has become more and more important, and more and more data exchange formats have been adopted for subsequent communication, such as the mainstream xml format, and with the development of data exchange formats, a A lightweight data exchange format, followed by json, JSON (JavaScript Object Notation) is a lightweight data exchange format. Easy for humans to read and write. It is also easy for machines to parse and generate. Compared with XML, the advantage of JSON is that the format is concise and short, especially when dealing with a large amount of complex data, this advantage is very prominent. [0003] As json has become the mainstream data format, the support for json in various languages ​​has become more and m...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F9/45
Inventor 蒋磊
Owner 北京思特奇信息技术股份有限公司
Features
  • R&D
  • Intellectual Property
  • Life Sciences
  • Materials
  • Tech Scout
Why Patsnap Eureka
  • Unparalleled Data Quality
  • Higher Quality Content
  • 60% Fewer Hallucinations
Social media
Patsnap Eureka Blog
Learn More