Method and device for generating code based on annotation and storage medium

A technology for generating code and comments, applied in the computer field, can solve problems such as inability to convert DTO and Entity, and achieve the effect of reducing the burden

Pending Publication Date: 2021-06-29
PINGAN PUHUI ENTERPRISE MANAGEMENT CO LTD
View PDF3 Cites 3 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The embodiment of this application provides a method, device and storage medium for generating code based on annotations, aiming to solve the problem that DTO and Entity cannot be directly converted in 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
  • Method and device for generating code based on annotation and storage medium
  • Method and device for generating code based on annotation and storage medium
  • Method and device for generating code based on annotation and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0023] The following will clearly and completely describe the technical solutions in the embodiments of the present application with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of them. Based on the embodiments in this application, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts belong to the scope of protection of this application.

[0024] It should be understood that when used in this specification and the appended claims, the terms "comprising" and "comprises" indicate the presence of described features, integers, steps, operations, elements and / or components, but do not exclude one or Presence or addition of multiple other features, integers, steps, operations, elements, components and / or collections thereof.

[0025] It should also be understood that the terminology used in the specificati...

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 discloses a method and device for generating codes based on annotations and a storage medium, and relates to the technical field of research and development management, and the method comprises the following steps: obtaining an interface document to be converted into codes; determining a first target class to be converted in the interface document, and determining a second target class; setting a first annotation label and a second annotation label for the first target class, wherein the first annotation label is used for indicating that the first target class is a class to be converted, and the second annotation label is used for indicating that the first target class is converted into a second target class; converting the first target class into the second target class according to the second annotation label; compiling the interface document according to the first annotation tag, the second annotation tag, the first target class and the second target class to obtain a source code file corresponding to the interface document. According to the scheme, additional auxiliary classes do not need to be written to help to generate the conversion codes, introduction dependency is reduced, loss caused by dependency introduction of all links of testing and deploying is reduced, and meanwhile the burden of the virtual machine during running can be reduced.

Description

technical field [0001] The present application relates to the field of computer technology, and in particular to a method, device and storage medium for generating code based on comments. Background technique [0002] Data Transfer Object (DTO) is a software application system that transfers data between design patterns, that is, DTO is an object responsible for transferring data between the application layer and the presentation layer. Data transfer targets are often data access objects that retrieve data from the database. The difference between Data Transfer Objects and Data Interaction Objects or Data Access Objects is that one does not have any behavior except storing and retrieving data (access and accessor), while DTO is used to encapsulate data into ordinary JavaBeans, in Transmission between multiple levels of J2EE. [0003] In database technology, data transfer objects (Data Transfer Object, DTO) are generally used to express the input and output parameters of th...

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): G06F8/41G06F11/36
CPCG06F8/41G06F11/3684G06F11/3688
Inventor 梁明
Owner PINGAN PUHUI ENTERPRISE MANAGEMENT CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products