A method and a terminal for automatically comparing interface document differences
An automatic comparison and interface technology, applied in version control, software maintenance/management, etc., can solve the problems of interface code inconsistency and low efficiency in interface differences, document content, etc., so as to improve communication efficiency, reduce workload, and avoid inconsistencies.
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0064] Please refer to figure 1 , a method for automatically comparing differences in interface documents, including steps:
[0065] Collect the interface document information of different versions of the software through the swagger framework;
[0066] S1. Extracting the first information of the interface documents of the two versions to be compared;
[0067] Wherein, the first information is json information;
[0068] S2. Automatically compare the first information of the interface documents of the two versions to be compared to obtain a comparison result;
[0069] Specifically, the first information of the two versions of the interface document to be compared is divided into first version information and second version information in chronological order;
[0070] Judging whether the interface address in the first version information exists in the second version information, if yes, the comparison result is that the interface address has not been changed; if not, the comp...
Embodiment 2
[0079] Apply the method described in Embodiment 1 to a specific scenario, in a java project:
[0080] Collect the interface documents generated by annotating the interface description through the swagger framework;
[0081] S1. Extracting the first information of the interface documents of the two versions to be compared;
[0082] Wherein, the first information is json information;
[0083] S2. Automatically compare the first information of the interface documents of the two versions to be compared to obtain a comparison result;
[0084] Specifically, a standard json document in swagger format is as follows:
[0085]
[0086]
[0087] Among them, the interface list is under the paths node, and the difference can be obtained by comparing the interface lists under the paths node of the two json documents. Specifically, the json information of the two versions of the interface documents to be compared is arranged in chronological order Divided into first version informat...
Embodiment 3
[0103] Please refer to figure 2 A terminal 1 for automatically comparing interface document differences, comprising a memory 2, a processor 3, and a computer program stored in the memory 2 and operable on the processor 3, when the processor 3 executes the computer program Each step in the first embodiment is realized.
[0104] To sum up, the present invention provides a method and terminal for automatically comparing interface document differences. By extracting the first information of the two versions of the interface documents to be compared, the two versions of the interface to be compared are automatically compared. The first information of the document, the comparison result is obtained, and the comparison result is displayed, which can realize the automatic display of the difference part of the interface document, and reduce the workload of developers manually sorting out the interface difference documents of different software versions. For interfaces with the same in...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com