Unlock instant, AI-driven research and patent intelligence for your innovation.

Method and device for optimizing Java codes

A java method and code optimization technology, applied in the field of Java code optimization, can solve problems such as inability to provide optimization strategies, achieve the effects of enhancing code readability, optimizing code, and reducing time and labor costs

Inactive Publication Date: 2018-11-30
BEIJING JINGDONG SHANGKE INFORMATION TECH CO LTD +1
View PDF4 Cites 1 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] In view of this, the embodiments of the present invention provide a Java code optimization method and device, which can solve the problem of being unable to provide an optimization strategy and perform optimization in the face of lengthy Java methods

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 optimizing Java codes
  • Method and device for optimizing Java codes
  • Method and device for optimizing Java codes

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0030] Exemplary embodiments of the present invention are described below in conjunction with the accompanying drawings, which include various details of the embodiments of the present invention to facilitate understanding, and they should be regarded as exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.

[0031] As described in the background technology of the present invention, there are many Java methods up to hundreds of lines in the codes of the prior art, and various behavior logics are all added to one method, which not only destroys the object-oriented behavior principle, but also It makes the code lose readability, increases the cost of code maintenance, and even ch...

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

An embodiment of the invention provides a method and a device for optimizing Java codes. The method includes acquiring Java methods in Class files and judging whether the Java methods are to-be-processed Java methods with line numbers higher than line number thresholds or not; carrying out data flow and control flow analysis on the to-be-processed Java methods if the Java methods are the to-be-processed Java methods with the line numbers higher than the line number thresholds; inputting data obtained by means of analysis into preliminarily trained models so as to optimize the to-be-processed Java methods. The method and the device have the advantage that the problems of incapability of providing optimization strategies and incapability of optimizing tediously long Java methods can be solved by the aid of the method and the device.

Description

technical field [0001] The invention relates to the field of computers, in particular to a method and device for optimizing Java codes. Background technique [0002] With the popularity of the Java language, many integrated development environments and development tools have emerged, such as Eclipse, IDEA and other mainstream development tools. These tools are also becoming more and more intelligent, and can provide many practical functions such as code repetition prompts, simple grammatical error prompts, automatic input completion, and establishment of reference relationship diagrams between classes, which greatly improves the efficiency of code development. [0003] In the course of realizing the present invention, the inventor finds that there are at least the following problems in the prior art: [0004] Although the solutions in the prior art can improve development efficiency and effectively perform code version control, they do not have the function of optimizing co...

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
IPC IPC(8): G06F8/20G06F8/41
CPCG06F8/24G06F8/443
Inventor 曾佳平
Owner BEIJING JINGDONG SHANGKE INFORMATION TECH CO LTD