CN107678968A - Sample extraction method, apparatus, computing device and the storage medium of source code function - Google Patents
Sample extraction method, apparatus, computing device and the storage medium of source code function Download PDFInfo
- Publication number
- CN107678968A CN107678968A CN201710972003.5A CN201710972003A CN107678968A CN 107678968 A CN107678968 A CN 107678968A CN 201710972003 A CN201710972003 A CN 201710972003A CN 107678968 A CN107678968 A CN 107678968A
- Authority
- CN
- China
- Prior art keywords
- function
- code
- sample
- file
- feature
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/362—Software debugging
- G06F11/366—Software debugging using diagnostics
Abstract
A kind of performed the invention discloses sample extraction method, apparatus of source code function, computing device, computer-readable storage medium and the obtained Sample Storehouse of sample extraction method based on above-mentioned source code function code search method, apparatus, computing device, computer-readable storage medium.The Sample Method of source code function includes:Obtain sound code file;The sound code file is parsed, segmentation obtains at least one function file;Extract the Function feature of at least one function file;The function sample of essential information comprising at least one function file and Function feature is stored in Sample Storehouse.The function in sound code file can individually be extracted by the sample extraction method of source code function, function is identified with the essential information and feature of function, sound code file is simply included to the function sample of function information and feature, can conveniently and efficiently obtain the relevant information of function.
Description
Technical field
The present invention relates to field of computer technology, and in particular to a kind of sample extraction method, apparatus of source code function, calculates
Equipment and computer-readable storage medium and a kind of Selecting Function System method, apparatus, computing device and computer-readable storage medium.
Background technology
At present, the iteration speed of internet is very fast, and in order to meet the needs of user, some companies can provide a variety of interconnections
For net product so that for users to use, each product item can have many codes, code includes some functions, and some
Function can be reused in different projects, therefore can have many potential bug, when being found that a function has bug,
Need to modify all items for having used the function, but often reliably foundation can check it to neither one
The function is also using in his which project, it is impossible to all projects using the function are modified in the lump, are repairing these
Larger workload can be faced when bug.
The content of the invention
In view of the above problems, it is proposed that the present invention so as to provide one kind overcome above mentioned problem or at least in part solve on
State the source code function of problem sample extraction method, apparatus, computing device and computer-readable storage medium and code search method,
Device, computing device and computer-readable storage medium.
According to an aspect of the invention, there is provided a kind of sample extraction method of source code function, including:
Obtain sound code file;
The sound code file is parsed, segmentation obtains at least one function file;
Extract the Function feature of at least one function file;
The function sample of essential information comprising at least one function file and Function feature is stored in Sample Storehouse.
According to another aspect of the present invention, there is provided a kind of sample extraction device of source code function, including:
Source code acquisition module, suitable for obtaining sound code file;
Split module, suitable for parsing the sound code file, segmentation obtains at least one function file;
Function feature extraction module, suitable for extracting the Function feature of at least one function file;
Enter library module, suitable for by the function sample of the essential information comprising at least one function file and Function feature
It is stored in Sample Storehouse.
According to another aspect of the invention, there is provided a kind of computing device, including:Processor, memory, communication interface and
Communication bus, the processor, the memory and the communication interface complete mutual communication by the communication bus;
The memory is used to deposit an at least executable instruction, and the executable instruction makes the computing device above-mentioned
Operated corresponding to the sample extraction method of source code function.
In accordance with a further aspect of the present invention, there is provided a kind of computer-readable storage medium, be stored with the storage medium to
A few executable instruction, the executable instruction make computing device be grasped as corresponding to the sample extraction method of above-mentioned source code function
Make.
According to an aspect of the invention, there is provided a kind of code search method, methods described is based on above-mentioned source code function
The obtained Sample Storehouse of sample extraction method and perform, including:
Obtain code to be searched;
The code is parsed, extracts the characteristic value of the code;
According to the characteristic value of the code, in the sample library inquiry and the function sample of the code matches;
The function sample inquired is provided to front end page to be shown.
According to another aspect of the present invention, there is provided a kind of code search device, including:
Code obtaining module, suitable for obtaining code to be searched;
Code characteristic extraction module, suitable for parsing the code, extract the characteristic value of the code;
Matching module, suitable for the characteristic value according to the code, in the sample library inquiry and the letter of the code matches
Numerical example;
Display module, it is shown suitable for providing the function sample inquired to front end page.
According to another aspect of the invention, there is provided a kind of electronic equipment, including:Processor, memory, communication interface and
Communication bus, the processor, the memory and the communication interface complete mutual communication by the communication bus;
The memory is used to deposit an at least executable instruction, and the executable instruction makes the computing device as above
State and operated corresponding to code search method.
In accordance with a further aspect of the present invention, there is provided a kind of computer-readable storage medium, be stored with the storage medium to
A few executable instruction, the executable instruction make computing device be operated as corresponding to above-mentioned code search method.
According to the sample extraction method of source code function provided by the invention, sound code file is obtained;Parse sound code file, segmentation
Obtain at least one function file;Extract the Function feature of at least one function file;At least one function file will be included
The function sample of essential information and Function feature is stored in Sample Storehouse.By extracting the function in sound code file, identified with feature
Function, formation function sample so that the function information included in sound code file is individually extracted, and sound code file is reduced to
Function sample including function information and feature.
According to the function Sample Storehouse obtained by the sample extraction method of above-mentioned source code function, it is proposed that a kind of code search
Technical scheme, according to the method for code search provided by the invention, obtain code to be searched;Code is parsed, extracts code
Characteristic value;According to the characteristic value of code, in the sample library inquiry and the function sample of code matches;The function sample that will be inquired
This offer front end page is shown, and by carrying out feature extraction to code to be searched, is identified with characteristic value to be searched
Code, scanned in above-mentioned function Sample Storehouse, treat the function sample in the characteristic value and function Sample Storehouse of searching code
Feature matched, it is hereby achieved that a kind of efficient Selecting Function System method, get with it is to be searched code dependent
Function information.
Described above is only the general introduction of technical solution of the present invention, in order to better understand the technological means of the present invention,
And can be practiced according to the content of specification, and in order to allow above and other objects of the present invention, feature and advantage can
Become apparent, below especially exemplified by the embodiment of the present invention.
Brief description of the drawings
By reading the detailed description of hereafter preferred embodiment, it is various other the advantages of and benefit it is common for this area
Technical staff will be clear understanding.Accompanying drawing is only used for showing the purpose of preferred embodiment, and is not considered as to the present invention
Limitation.And in whole accompanying drawing, identical part is denoted by the same reference numerals.In the accompanying drawings:
Fig. 1 shows the flow chart of the sample extraction method of source code function according to an embodiment of the invention;
Fig. 2 shows the flow chart of the sample extraction method of source code function in accordance with another embodiment of the present invention;
Fig. 3 shows the functional block diagram of the sample extraction device of the source code function according to another embodiment of the invention;
Fig. 4 shows a kind of structural representation of computing device according to embodiments of the present invention;
Fig. 5 shows the flow chart of code search method in accordance with another embodiment of the present invention;
Fig. 6 shows the flow chart of the code search method according to another embodiment of the invention;
Fig. 7 shows the functional block diagram of the code search device according to further embodiment of the present invention;
Fig. 8 shows the structural representation of code search computing device according to embodiments of the present invention.
Embodiment
The exemplary embodiment of the disclosure is more fully described below with reference to accompanying drawings.Although the disclosure is shown in accompanying drawing
Exemplary embodiment, it being understood, however, that may be realized in various forms the disclosure without should be by embodiments set forth here
Limited.On the contrary, these embodiments are provided to facilitate a more thoroughly understanding of the present invention, and can be by the scope of the present disclosure
Completely it is communicated to those skilled in the art.
Some companies can provide a variety of internet products so that for users to use, each product item can have many generations
Code, code includes some functions, when comparing during the essential information of one function of acquisition from many individual item destination codes
Complicated, the present embodiment then provides a kind of sample extraction method of source code function, can be realized sound code file by this method
In function split, and the function in sound code file is identified in a manner of concise, can intuitively obtain function
Relevant information and feature.
Fig. 1 shows the flow chart of the sample extraction method of source code function according to an embodiment of the invention.Such as Fig. 1 institutes
Show, this method comprises the following steps:
Step S101, obtain sound code file.
Being obtained from various approach needs the sound code file into line function sample extraction.
Step S102, parses sound code file, and segmentation obtains at least one function file.
The sound code file got is parsed using function split plot design, the function that sound code file is included is partitioned into
Come, obtain at least one function file.
Step S103, extract the Function feature of at least one function file.
By being extracted to the Function feature of function file, the function in sound code file is identified with Function feature, by
It is unique in the Function feature corresponding to function, the feature of different functions is differing from each other, therefore by extracting function file
Function feature, a function namely one section of code can be reduced to Function feature.
Step S104, the function sample of the essential information comprising at least one function file and Function feature is stored in sample
Storehouse.
Such as the sound code file of all items engineering of a company is all subjected to Function feature extraction, due to same functions
Function feature it is consistent, if only using Function feature as function sample write Sample Storehouse, related personnel when inquiring about the function,
Or the specifying information of function can not be learnt, such as the path where function, the project name where function, therefore also need to tie
The essential information for closing function is distinguish between to function.
The sample extraction method for the source code function that the present embodiment provides, by obtaining sound code file, sound code file is parsed, point
Cut to obtain at least one function file included in sound code file, extract the Function feature of at least one function file, use function
Feature identifies the function in sound code file, and by the essential information comprising at least one function file and the letter of Function feature
Numerical example is stored in Sample Storehouse.The function in sound code file can individually be extracted by the sample extraction method of source code function
Come, function is identified with the essential information and feature of function, sound code file simply includes to the function of function information and feature
Sample, it can conveniently and efficiently obtain the relevant information of function.
Fig. 2 shows the flow chart of the sample extraction method of source code function in accordance with another embodiment of the present invention.Such as Fig. 2
It is shown, comprise the following steps:
Step S201, obtains sound code file from code storage.
For example, the code of its all projects is centrally stored in code storage by a company, but due to code
Quantity it is bigger, can be cumbersome when to transfer some function in code storage.In the present embodiment, from code
Sound code file is obtained in warehouse, for carrying out sample extraction processing.
Step S202, filtration treatment is carried out to sound code file and/or standardization processing is carried out to sound code file, removes source code
Annotation in file.
Because the header file in sound code file, resource document etc. to sound code file when splitting, it is like water off a duck's back and
The result of possible influence function segmentation, and annotation can influence the extraction result to function file, so entering to sound code file
Need to be pre-processed before row segmentation.
Function feature extraction is that every line code of function file is handled, and removes the unnecessary blank character in two sides, so
The characteristic value of function file, and check value of the function file per a line are calculated afterwards, obtain the unique mark of function file.Thus
Understand, each character has an impact to final Function feature in function, needs to avoid unnecessary information from disturbing for this, especially
It is to remove the annotation in sound code file.
Preferably, sound code file is analyzed, the note in sound code file is determined with reference to the regular expression pre-set
Release, remove annotation.The method for removing code annotation on basis is the method replaced based on regular expression, in the present embodiment, is adopted
Analyzed with to sound code file, being capable of the significantly more efficient note determined in sound code file with reference to the regular expression pre-set
Release.
Preferably, the regular expression pre-set is:r'/\*(.|\n)**/' and r' // .*', using this canonical table
Can avoid regular expression is immature from causing to remove code annotation failure up to formula, such as regular expression r'/* .**/' do not have
Have a situation in view of annotation line feed, regular expression r'/* (| n) * */' not account for regular expression greedy/lazy
Property matched rule, regular expression r' // .* n' only annotate enter a new line in the case of come into force, to function file last column generation
Code annotation does not come into force, and these situations can all cause to remove code annotation failure or inaccurate.
Step S203, sound code file of the parsing by pretreatment, segmentation obtain at least one function.
Specifically, sound code file is parsed, extracts the function information of the function in sound code file, wherein, function information bag
Include:The path of file where function name, function, by the function information of analytic function, segmentation obtains function file, wherein,
For each function file, using function name as function file name, using the path of file where function as function file
Storage address.
By splitting to sound code file, the function in sound code file, and the essential information of function can be obtained.
Sound code file is carried out parse during segmentation obtains function file above-mentioned, letter occurs in overload function of the same name
Number file covering phenomenon, causes function file segmentation failure, when function is retrieved or carries out other application, function identification error.
In view of the above-mentioned problems, the present embodiment on the basis of function segmentation, increases overload function of the same name text where function
The function line number of part, function name and function line number are combined to the letter as function file corresponding to function name identical function
Number filename, because the function line number of file where function name identical function is inconsistent, letter is carried out using the method
The differentiation of number filename, it is possible to prevente effectively from overload function file of the same name covers phenomenon.
Preferably, when multiple projects all include Same Function, the path of file where item id and function is combined and made
For the storage address of function file.
Step S204, the MD5 values of at least one function, and the check value of every a line of at least one function are calculated, made
For the Function feature of function file.
By being extracted to the Function feature of function file, the function in sound code file is identified with Function feature, by
It is unique in the Function feature corresponding to function, the feature of different functions is differing from each other, by function MD5 values in the present embodiment
And the check value Function feature the most per a line, a function file is reduced to Function feature.
Step S205, by path, the code storehouse of file where the function file name comprising at least one function file, function
The function sample deposit Sample Storehouse of storehouse address of service, the lines of code of function and Function feature.
Such as the sound code file of all items engineering of a company is all subjected to Function feature extraction, due to same functions
Function feature it is consistent, if only using Function feature as function sample write Sample Storehouse, related personnel when inquiring about the function,
Or the specifying information of function can not be learnt, such as the path where function, the project name where function, therefore also need to tie
The essential information for closing function is distinguish between to function.In the present embodiment, the essential information of function includes above-mentioned parsing sound code file
During the function information of function that extracts, by by the path of file, code storage service where function file name, function
Address, function lines of code associative function MD5 values and function per a line check value be used as function sample, inquiring about letter
During numerical example, the essential information and fast positioning function of function can be obtained.
The sample extraction method for the source code function that the present embodiment provides, by obtaining sound code file from code storage, solution
Analyse sound code file, segmentation obtain at least one function file included in sound code file, calculate function file MD5 values and often
The check value of a line is as Function feature, and by the essential information comprising at least one function file and the function of Function feature
Sample is stored in Sample Storehouse.The function in sound code file can individually be extracted by the sample extraction method of source code function,
Function is identified with the essential information and feature of function, sound code file can be reduced to include the function sample of function information,
Sound code file is simply included to the function sample of function information and feature, can conveniently and efficiently obtain the related letter of function
Breath.
Fig. 3 shows the functional block diagram of the sample extraction device of the source code function according to another embodiment of the invention.Such as
Shown in Fig. 3, the device is included with lower module:
Source code acquisition module 301, suitable for obtaining sound code file.
Split module 302, suitable for parsing sound code file, segmentation obtains at least one function file.
Using function split plot design, the function in sound code file is split.
Function feature extraction module 303, suitable for extracting the Function feature of at least one function file.
Enter library module 304, suitable for by the function sample of the essential information comprising at least one function file and Function feature
It is stored in Sample Storehouse.
The sample extraction device for the source code function that the present embodiment provides, by obtaining sound code file, sound code file is parsed, point
Cut to obtain at least one function file included in sound code file, extract the Function feature of at least one function file, use function
Feature identifies the function in sound code file, and by the essential information comprising at least one function file and the letter of Function feature
Numerical example is stored in Sample Storehouse.The function in sound code file can individually be extracted by the sample extraction method of source code function
Come, function is identified with the essential information and feature of function, sound code file simply includes to the function of function information and feature
Sample, it can conveniently and efficiently obtain the relevant information of function.
Specifically, in another embodiment of the present invention,
Source code acquisition module 301 is further, suitable for obtaining sound code file from code storage.
Segmentation module 302 is further adapted for, and parses sound code file, extracts the letter of at least one function in sound code file
Number information, wherein, function information includes:The path of file where function name, function;
The function information of at least one function is analyzed, segmentation obtains at least one function file;Wherein, for each letter
Number file, using function name as function file name, the storage address using the path of file where function as function file.
Segmentation module 302 is further adapted for, and judges to whether there is function name identical function at least one function;
If so, the function line number of file where then extracting function name identical function, by function name and function line number
Combine the function file name as function file corresponding to function name identical function.
Function feature extraction module 303 is further adapted for, and calculates the MD5 values of at least one function, and at least one letter
The check value of several every a line, the Function feature as function file.
Enter library module 304 to be further adapted for, by file where the function file name comprising at least one function file, function
Path, code storage server address, the function sample deposit Sample Storehouse of the lines of code of function and Function feature.
Preferably, the sample extraction device of above-mentioned source code function also includes:Filtering module, suitable for being carried out to sound code file
Filter is handled, and removes header file and resource document etc. in sound code file.
Preferably, the sample extraction device of above-mentioned source code function also includes:Normalizing block, suitable for being carried out to sound code file
Standardization processing, remove the annotation in sound code file.
The sample extraction device for the source code function that the present embodiment provides, by obtaining sound code file from code storage, solution
Analyse sound code file, segmentation obtain at least one function file included in sound code file, calculate function file MD5 values and often
The check value of a line is as Function feature, and by the essential information comprising at least one function file and the function of Function feature
Sample is stored in Sample Storehouse.The function in sound code file can individually be extracted by the sample extraction method of source code function,
Function is identified with the essential information and feature of function, sound code file can be reduced to include the function sample of function information,
The relevant information of function can conveniently and efficiently be obtained.
The embodiment of the present application provides a kind of nonvolatile computer storage media, and the computer-readable storage medium is stored with
An at least executable instruction, the computer executable instructions can perform the sample of one source code function in above-mentioned any means embodiment
This extracting method.
Fig. 4 shows a kind of structural representation of computing device according to embodiments of the present invention, the specific embodiment of the invention
The specific implementation to computing device does not limit.
As shown in figure 4, the computing device can include:Processor (processor) 402, communication interface
(Communications Interface) 404, memory (memory) 406 and communication bus 408.
Wherein:
Processor 402, communication interface 404 and memory 406 complete mutual communication by communication bus 408.
Communication interface 404, for being communicated with the network element of miscellaneous equipment such as client or other servers etc..
Processor 402, for configuration processor 410, the sample extraction method that can specifically perform above-mentioned source code function is implemented
Correlation step in example.
Specifically, program 410 can include program code, and the program code includes computer-managed instruction.
Processor 402 is probably central processor CPU, or specific integrated circuit ASIC (Application
Specific Integrated Circuit), or it is arranged to implement the integrated electricity of one or more of the embodiment of the present invention
Road.The one or more processors that computing device includes, can be same type of processor, such as one or more CPU;Also may be used
To be different types of processor, such as one or more CPU and one or more ASIC.
Memory 406, for depositing program 410.Memory 406 may include high-speed RAM memory, it is also possible to also include
Nonvolatile memory (non-volatile memory), for example, at least a magnetic disk storage.
Program 410 specifically can be used for so that processor 402 performs following operation:
Obtain sound code file;
Sound code file is parsed, segmentation obtains at least one function file;
Extract the Function feature of at least one function file;
The function sample of essential information comprising at least one function file and Function feature is stored in Sample Storehouse.
Program 410 specifically can be also used for so that processor 402 performs following operation:
Sound code file is obtained from code storage.
Program 410 specifically can be also used for so that processor 402 performs following operation:
Sound code file is parsed, extracts the function information of at least one function in sound code file, wherein, function information bag
Include:The path of file where function name, function;
The function information of at least one function is analyzed, segmentation obtains at least one function file;Wherein, for each letter
Number file, using function name as function file name, the storage address using the path of file where function as function file.
Program 410 specifically can be also used for so that processor 402 performs following operation:
Judge to whether there is function name identical function at least one function;
If so, the function line number of file where then extracting function name identical function, by function name and function line number
Combine the function file name as function file corresponding to function name identical function.
Program 410 specifically can be also used for so that processor 402 performs following operation:
The MD5 values of at least one function, and the check value of every a line of at least one function are calculated, as function file
Function feature.
Program 410 specifically can be also used for so that processor 402 performs following operation:
By the path of file, code storage server where the function file name comprising at least one function file, function
The function sample deposit Sample Storehouse of address, the lines of code of function and Function feature.
Program 410 specifically can be also used for so that processor 402 performs following operation:
Filtration treatment is carried out to sound code file.
Program 410 specifically can be also used for so that processor 402 performs following operation:
Standardization processing is carried out to sound code file, removes the annotation in sound code file.
Program 410 specifically can be also used for so that processor 402 performs following operation:
Semantic analysis is carried out to code, the annotation in sound code file is determined with reference to the regular expression pre-set, is removed
Annotation.
Based on Sample Storehouse obtained from above-mentioned source code function sample extraction method, the invention also provides a kind of code search
Method, the iteration speed of internet is very fast, has the code much repeated unavoidably in some product items, exists many latent
Bug, when finding that a function has bug, it is necessary to modified all using the project of the function, but often without one
Individual reliable foundation, which can be checked in other which projects, has used the function, and therefore, the present invention proposes one kind in sample
The method scanned in storehouse to code, the project using this section of code can be quickly found, improve the work of related personnel
Make efficiency.
Fig. 5 shows the flow chart of code search method in accordance with another embodiment of the present invention.As shown in figure 5, the party
Method comprises the following steps:
Step S501, obtain code to be searched.
Developer or tester have found bug be present in product, and can obtain the related generation for producing this bug
Code, then related personnel can be scanned for this section of code, and certainly, user can also be carried out to the code that other any approach obtain
Search, is not construed as limiting herein.
Step S502, code is parsed, extract the characteristic value of code.
The method of the present embodiment is based on Sample Storehouse obtained from above-mentioned function sample extraction method, and code is scanned for
When, it is necessary to match the feature of the characteristic value and function sample of code.By parsing code, the characteristic value of code is extracted, due to
Function feature corresponding to code is unique, and the characteristic value of different code is differing from each other, therefore by extracting the spy of code
Sign, code can be reduced to be capable of the characteristic value of unique identification code.
Step S503, according to the characteristic value of code, in sample library inquiry and the function sample of code matches.
The Sample Storehouse obtained based on above-mentioned function sample extraction method, the present embodiment, will generations when being scanned for code
The feature of the characteristic value and function sample of code is matched, and according to default matching algorithm, obtains matching result.
Step S504, provide the function sample inquired to front end page and be shown.
It is that step S503 is obtained with code matches to be searched function samples, there is provided shown to front end page.
The method of the code search provided according to the present embodiment, obtains code to be searched;Code is parsed, extracts code
Characteristic value;According to the characteristic value of code, in sample library inquiry and the function sample of code matches;The function sample inquired is carried
It is shown for front end page, by carrying out feature extraction to code to be searched, when being scanned for code to be searched,
The feature for treating the function sample in the characteristic value and function Sample Storehouse of searching code is matched, and can be obtained a kind of efficient
Selecting Function System method, and the essential information of code to be searched can be obtained in search result.
Fig. 6 shows the flow chart of the code search method according to another embodiment of the invention.As shown in fig. 6, the party
Method includes:
Step S601, obtain code snippet or function to be searched.
In the present embodiment, user can submit the code snippet or function that need to search for by front end page.
Step S602, check value of the calculation code fragment per a line, the characteristic value as code snippet;Or calculating function is every
The check value and MD5 values of a line, the characteristic value as function.
User can provide code snippet or function scans for, and the characteristic value extracted for code snippet or function is not
Unanimously, function MD5 values and function name is corresponding, therefore when the simply code snippet, a rather than full function of user's offer
The check value of body, the then every a line of calculation code fragment, and if what is submitted is a function, then need to calculate the every a line of function
Check value and function MD5 values.
Step S603, according to the characteristic value of code snippet or function, sample library inquiry respectively with code snippet or function
The function sample of matching.
Search of the present embodiment to code snippet or function is to be based on sample obtained from above-mentioned function sample extraction method
What this storehouse was carried out, after the characteristic value for extracting code snippet or function, according to default matching algorithm to function in Sample Storehouse
The feature and code snippet of sample or the characteristic value of function are matched, and are obtained and code snippet to be searched or functional dependence
Function sample.
Specifically, if code to be searched is function, whether the MD5 with code to be searched is included in judgement sample storehouse
It is worth consistent function sample, if, it is determined that the function sample is the first class function sample with code matches.
Whether included if code to be searched is function or code snippet, in judgement sample storehouse every with code to be searched
The consistent function sample of the check value and lines of code of a line, if, it is determined that the function sample is the with code matches
Two class function samples.
According to the check value identical proportion of function sample in the check value and Sample Storehouse of code to be searched, and wait to search
The difference of the lines of code of function sample in the lines of code and Sample Storehouse of the code of rope, calculates code and Sample Storehouse to be searched
The matching value of middle function sample, ranking is carried out to function sample according to matching value and obtains the 3rd class function sample.
Specifically, the check value identical proportion of function sample refers to treat in the check value and Sample Storehouse of code to be searched
The check value identical line number of function sample accounts for total line number of code to be searched in the check value and Sample Storehouse of the code of search
Proportion, in code and Sample Storehouse to be searched in check value and Sample Storehouse of the matching value of function sample with code to be searched
The check value identical proportion of function sample is directly proportional, with the function sample in the lines of code and Sample Storehouse of code to be searched
The difference of lines of code be inversely proportional, set the check value of code to be searched identical with the check value of function sample in Sample Storehouse
Proportion and code to be searched lines of code weight corresponding with the difference of lines of code in Sample Storehouse, weighting sum be
For the matching value of function sample in code to be searched and Sample Storehouse.
Wherein, the ranking of the first class function sample is higher than the second class function sample, and the ranking of the second class function sample is higher than
3rd class function sample.
Step S604, provide the function sample inquired to front end page and be shown.
It is supplied to front end page to enter in the above-mentioned function sample inquiring with code snippet to be searched or functional dependence
Row display.
The method of the code search provided according to the present embodiment, user can provide code snippet or function scans for, and lead to
Parsing code snippet or function are crossed, extracts the characteristic value of code snippet or function, according to the characteristic value of code or function, in sample
The function sample that library inquiry matches with code snippet;There is provided the function sample inquired to front end page to be shown, by right
Code snippet to be searched or function carry out feature extraction, when being scanned for code snippet or function to be searched, treat
Searching code fragment or the feature of the function sample in the characteristic value and function Sample Storehouse of function are matched, and can obtain one kind
Efficient Selecting Function System method, and the essential information of code to be searched can be obtained in search result.
Fig. 7 shows the functional block diagram of the code search device according to further embodiment of the present invention.As shown in fig. 7, should
Device includes:
Code obtaining module 701, suitable for obtaining code to be searched;
Code characteristic extraction module 702, suitable for parsing code, extract the characteristic value of code;
Matching module 704, suitable for the characteristic value according to code, in sample library inquiry and the function sample of code matches;
Display module 704, it is shown suitable for providing the function inquired sample to front end page.
Specifically, in another embodiment of invention,
Code characteristic extraction module S702 is further adapted for, if code to be searched is code snippet, calculation code piece
Check value of the section per a line;
If code to be searched is function, the check value of the MD5 values and function of function per a line is calculated.
Matching module S704 is further adapted for, if code to be searched is function, in judgement sample storehouse whether include with
The consistent function sample of the MD5 values of code to be searched, if, it is determined that the function sample is the first kind letter with code matches
Numerical example.
Whether included if code to be searched is function or code snippet, in judgement sample storehouse every with code to be searched
The consistent function sample of the check value and lines of code of a line, if, it is determined that the function sample is the with code matches
Two class function samples.
According to the check value identical proportion of function sample in the check value and Sample Storehouse of code to be searched, and wait to search
The difference of the lines of code of function sample in the lines of code and Sample Storehouse of the code of rope, calculates code and Sample Storehouse to be searched
The matching value of middle function sample, ranking is carried out to function sample according to matching value and obtains the 3rd class function sample;
Wherein, the ranking of the first class function sample is higher than the second class function sample, and the ranking of the second class function sample is higher than
3rd class function sample.
According to the device of code search provided by the invention, code to be searched is obtained;Parse code, the spy for extracting code
Value indicative;According to the characteristic value of code, in sample library inquiry and the function sample of code matches;The function sample inquired is provided
Front end page is shown, right when being scanned for code to be searched by carrying out feature extraction to code to be searched
The feature of function sample in the characteristic value and function Sample Storehouse of code to be searched is matched, and can obtain a kind of efficient letter
Number searching method.
The embodiment of the present application provides a kind of nonvolatile computer storage media, and the computer-readable storage medium is stored with
An at least executable instruction, the computer executable instructions can perform the sample of one source code function in above-mentioned any means embodiment
This extracting method.
Fig. 8 shows the structural representation of code search computing device according to embodiments of the present invention, of the invention specific real
Specific implementation of the example not to computing device is applied to limit.
As shown in figure 8, the computing device can include:Processor (processor) 802, communication interface
(Communications Interface) 804, memory (memory) 806 and communication bus 808.
Wherein:
Processor 802, communication interface 804 and memory 806 complete mutual communication by communication bus 808.
Communication interface 804, for being communicated with the network element of miscellaneous equipment such as client or other servers etc..
Processor 802, for configuration processor 810, the sample extraction method that can specifically perform above-mentioned source code function is implemented
Correlation step in example.
Specifically, program 810 can include program code, and the program code includes computer-managed instruction.
Processor 802 is probably central processor CPU, or specific integrated circuit ASIC (Application
Specific Integrated Circuit), or it is arranged to implement the integrated electricity of one or more of the embodiment of the present invention
Road.The one or more processors that computing device includes, can be same type of processor, such as one or more CPU;Also may be used
To be different types of processor, such as one or more CPU and one or more ASIC.
Memory 806, for depositing program 810.Memory 806 may include high-speed RAM memory, it is also possible to also include
Nonvolatile memory (non-volatile memory), for example, at least a magnetic disk storage.
Program 810 specifically can be used for so that processor 802 performs following operation:
Obtain code to be searched;
Code is parsed, extracts the characteristic value of code;
According to the characteristic value of code, in sample library inquiry and the function sample of code matches;
The function sample inquired is provided to front end page to be shown.
Program 810 specifically can be also used for so that processor 802 performs following operation:
If code to be searched is code snippet, check value of the calculation code fragment per a line;
If code to be searched is function, the check value of the MD5 values and function of function per a line is calculated.
Program 810 specifically can be also used for so that processor 802 performs following operation:
Whether included if code to be searched is function, in judgement sample storehouse consistent with the MD5 values of code to be searched
Function sample, if, it is determined that the function sample is the first class function sample with code matches.
Program 810 specifically can be also used for so that processor 802 performs following operation:
Whether included if code to be searched is function or code snippet, in judgement sample storehouse every with code to be searched
The consistent function sample of the check value and lines of code of a line, if, it is determined that the function sample is the with code matches
Two class function samples.
Program 810 specifically can be also used for so that processor 802 performs following operation:
According to the check value identical proportion of function sample in the check value and Sample Storehouse of code to be searched, and wait to search
The difference of the lines of code of function sample in the lines of code and Sample Storehouse of the code of rope, calculates code and Sample Storehouse to be searched
The matching value of middle function sample, ranking is carried out to function sample according to matching value and obtains the 3rd class function sample;
Wherein, the ranking of the first class function sample is higher than the second class function sample, and the ranking of the second class function sample is higher than
3rd class function sample.
Algorithm and display be not inherently related to any certain computer, virtual system or miscellaneous equipment provided herein.
Various general-purpose systems can also be used together with teaching based on this.As described above, required by constructing this kind of system
Structure be obvious.In addition, the present invention is not also directed to any certain programmed language.It should be understood that it can utilize various
Programming language realizes the content of invention described herein, and the description done above to language-specific is to disclose this hair
Bright preferred forms.
In the specification that this place provides, numerous specific details are set forth.It is to be appreciated, however, that the implementation of the present invention
Example can be put into practice in the case of these no details.In some instances, known method, structure is not been shown in detail
And technology, so as not to obscure the understanding of this description.
Similarly, it will be appreciated that in order to simplify the disclosure and help to understand one or more of each inventive aspect,
Above in the description to the exemplary embodiment of the present invention, each feature of the invention is grouped together into single implementation sometimes
In example, figure or descriptions thereof.However, the method for the disclosure should be construed to reflect following intention:I.e. required guarantor
The application claims of shield features more more than the feature being expressly recited in each claim.It is more precisely, such as following
Claims reflect as, inventive aspect is all features less than single embodiment disclosed above.Therefore,
Thus the claims for following embodiment are expressly incorporated in the embodiment, wherein each claim is in itself
Separate embodiments all as the present invention.
Those skilled in the art, which are appreciated that, to be carried out adaptively to the module in the equipment in embodiment
Change and they are arranged in one or more equipment different from the embodiment.Can be the module or list in embodiment
Member or component be combined into a module or unit or component, and can be divided into addition multiple submodule or subelement or
Sub-component.In addition at least some in such feature and/or process or unit exclude each other, it can use any
Combination is disclosed to all features disclosed in this specification (including adjoint claim, summary and accompanying drawing) and so to appoint
Where all processes or unit of method or equipment are combined.Unless expressly stated otherwise, this specification (including adjoint power
Profit requires, summary and accompanying drawing) disclosed in each feature can be by providing the alternative features of identical, equivalent or similar purpose come generation
Replace.
In addition, it will be appreciated by those of skill in the art that although some embodiments described herein include other embodiments
In included some features rather than further feature, but the combination of the feature of different embodiments means in of the invention
Within the scope of and form different embodiments.For example, in the following claims, embodiment claimed is appointed
One of meaning mode can use in any combination.
The all parts embodiment of the present invention can be realized with hardware, or to be run on one or more processor
Software module realize, or realized with combinations thereof.It will be understood by those of skill in the art that it can use in practice
Microprocessor or digital signal processor (DSP) come realize according to embodiments of the present invention one and two computing devices some or
The some or all functions of person's whole part.The present invention is also implemented as perform method as described herein one
Divide either whole equipment or program of device (for example, computer program and computer program product).It is such to realize this hair
Bright program can store on a computer-readable medium, or can have the form of one or more signal.It is such
Signal can be downloaded from internet website and obtained, and either provided on carrier signal or provided in the form of any other.
It should be noted that the present invention will be described rather than limits the invention for above-described embodiment, and ability
Field technique personnel can design alternative embodiment without departing from the scope of the appended claims.In the claims,
Any reference symbol between bracket should not be configured to limitations on claims.Word "comprising" does not exclude the presence of not
Element or step listed in the claims.Word "a" or "an" before element does not exclude the presence of multiple such
Element.The present invention can be by means of including the hardware of some different elements and being come by means of properly programmed computer real
It is existing.In if the unit claim of equipment for drying is listed, several in these devices can be by same hardware branch
To embody.The use of word first, second, and third does not indicate that any order.These words can be explained and run after fame
Claim.
The invention discloses:
A1. a kind of sample extraction method of source code function, including:
Obtain sound code file;
The sound code file is parsed, segmentation obtains at least one function file;
Extract the Function feature of at least one function file;
The function sample of essential information comprising at least one function file and Function feature is stored in Sample Storehouse.
A2. the method according to A1, wherein, the acquisition sound code file further comprises:
Sound code file is obtained from code storage.
A3. the method according to A1 or A2, wherein, the parsing sound code file, segmentation obtains at least one letter
Number file further comprises:
The sound code file is parsed, extracts the function information of at least one function in the sound code file, wherein, institute
Stating function information includes:The path of file where function name, function;
The function information of at least one function is analyzed, segmentation obtains at least one function file;Wherein, for
Each function file, using the function name as function file name, using the path of file where the function as described in
The storage address of function file.
A4. the method according to A3, wherein, the function information of at least one function of analysis, segmentation obtains described
At least one function file further comprises:
Judge to whether there is function name identical function at least one function;
If so, the function line number of file where then extracting function name identical function, by function name and function line number
Combine the function file name as function file corresponding to the function name identical function.
A5. the method according to any one of A1-A4, wherein, the letter of extraction at least one function file
Number feature further comprises:
The MD5 values of at least one function, and the check value of every a line of at least one function are calculated, as
The Function feature of function file.
A6. the method according to any one of A1-A5, wherein, it is described to include the basic of at least one function
The function sample of information and Function feature deposit Sample Storehouse further comprises:
By the path of file, code storage clothes where the function file name comprising at least one function file, function
The function sample deposit Sample Storehouse of business device address, the lines of code of function and Function feature.
A7. the method according to any one of A1-A6, wherein, the parsing sound code file, segmentation obtains at least
Before the step of one function, methods described further comprises:
Filtration treatment is carried out to the sound code file.
A8. the method according to any one of A1-A7, wherein, the parsing sound code file, segmentation obtains at least
Before the step of one function, methods described further comprises:
Standardization processing is carried out to the sound code file, removes the annotation in the sound code file.
A9. the method according to A8, wherein, it is described that standardization processing is carried out to the sound code file, remove the source
Annotation in code file further comprises:
Semantic analysis is carried out to code, the annotation in the sound code file is determined with reference to the regular expression pre-set,
Remove the annotation.
B10. a kind of code search method, methods described according to the method any one of above-mentioned A1-A9 based on obtaining
Sample Storehouse and perform, methods described includes:
Obtain code to be searched;
The code is parsed, extracts the characteristic value of the code;
According to the characteristic value of the code, in the sample library inquiry and the function sample of the code matches;
The function sample inquired is provided to front end page to be shown.
B11. the method according to B10, wherein, the parsing code, the characteristic value for extracting the code enters one
Step includes:
If the code to be searched is code snippet, check value of the code snippet per a line is calculated;
If the code to be searched is function, the school of the MD5 values and the function of the function per a line is calculated
Test value.
B12. the method according to B11, wherein, the characteristic value according to the code, in the sample library inquiry
Further comprise with the function sample of the code matches:
If the code to be searched is function, judge whether included and code to be searched in the Sample Storehouse
The consistent function sample of MD5 values, if, it is determined that the function sample is the first class function sample with the code matches.
B13. the method according to B12, wherein, the characteristic value according to the code, in the sample library inquiry
Further comprise with the function sample of the code matches:
If the code to be searched is function or code snippet, judge in the Sample Storehouse whether to include with it is to be searched
Check value and lines of code consistent function sample of the code per a line, if, it is determined that the function sample be with it is described
Second class function sample of code matches.
B14. the method according to B13, wherein, the characteristic value according to the code, in the sample library inquiry
Further comprise with the function sample of the code matches:
According to the check value identical proportion of the check value and function sample in the Sample Storehouse of code to be searched, and
The difference of the lines of code of code to be searched and the lines of code of function sample in the Sample Storehouse, calculates code to be searched
With the matching value of function sample in the Sample Storehouse, ranking is carried out to function sample according to matching value and obtains the 3rd class function sample
This;
The ranking of the first class function sample is higher than the second class function sample, the row of the second class function sample
Name is higher than the 3rd class function sample.
C15. a kind of sample extraction device of source code function, including:
Source code acquisition module, suitable for obtaining sound code file;
Split module, suitable for parsing the sound code file, segmentation obtains at least one function file;
Function feature extraction module, suitable for extracting the Function feature of at least one function file;
Enter library module, suitable for by the function sample of the essential information comprising at least one function file and Function feature
It is stored in Sample Storehouse.
C16. the device according to C15, wherein, the source code acquisition module is further adapted for:
Sound code file is obtained from code storage.
C17. the device according to C15 or C16, wherein, the segmentation module is further adapted for:
The sound code file is parsed, extracts the function information of at least one function in the sound code file, wherein, institute
Stating function information includes:The path of file where function name, function;
The function information of at least one function is analyzed, segmentation obtains at least one function file;Wherein, for
Each function file, using the function name as function file name, using the path of file where the function as described in
The storage address of function file.
C18. the device according to C17, wherein, the segmentation module is further adapted for:
Judge to whether there is function name identical function at least one function;
If so, the function line number of file where then extracting function name identical function, by function name and function line number
Combine the function file name as function file corresponding to the function name identical function.
C19. the device according to any one of C15-C18, wherein, the Function feature extraction element is further adapted for:
The MD5 values of at least one function, and the check value of every a line of at least one function are calculated, as
The Function feature of function file.
C20. the device according to any one of C15-C19, wherein, it is described enter library module be further adapted for:
By the path of file, code storage clothes where the function file name comprising at least one function file, function
The function sample deposit Sample Storehouse of business device address, the lines of code of function and Function feature.
C21. the device according to any one of C15-C20, wherein, described device further comprises:
Filtering module, suitable for carrying out filtration treatment to sound code file.
C22. the device according to any one of C15-C21, wherein, described device further comprises:
Normalizing block, suitable for carrying out standardization processing to the sound code file, remove the annotation in the sound code file.
C23. the device according to C22, wherein, the normalizing block is further adapted for:
Semantic analysis is carried out to code, the annotation in the sound code file is determined with reference to the regular expression pre-set,
Remove the annotation.
D24. a kind of code search device, including:
Code obtaining module, suitable for obtaining code to be searched;
Code characteristic extraction module, suitable for parsing the code, extract the characteristic value of the code;
Matching module, suitable for the characteristic value according to the code, in the sample library inquiry and the letter of the code matches
Numerical example;
Display module, it is shown suitable for providing the function sample inquired to front end page.
D25. the device according to D24, wherein, the code characteristic extraction module is further adapted for:
If the code to be searched is code snippet, check value of the code snippet per a line is calculated;
If the code to be searched is function, the school of the MD5 values and the function of the function per a line is calculated
Test value.
D26. the device according to D25, wherein, the matching module is further adapted for:
If the code to be searched is function, judge whether included and code to be searched in the Sample Storehouse
The consistent function sample of MD5 values, if, it is determined that the function sample is the first class function sample with the code matches.
D27. the device according to D26, wherein, the matching module is further adapted for:
If the code to be searched is function or code snippet, judge in the Sample Storehouse whether to include with it is to be searched
Check value and lines of code consistent function sample of the code per a line, if, it is determined that the function sample be with it is described
Second class function sample of code matches.
D28. the method according to D27, wherein, the matching module is further adapted for:
According to the check value identical proportion of the check value and function sample in the Sample Storehouse of code to be searched, and
The difference of the lines of code of code to be searched and the lines of code of function sample in the Sample Storehouse, calculates code to be searched
With the matching value of function sample in the Sample Storehouse, ranking is carried out to function sample according to matching value and obtains the 3rd class function sample
This;
The ranking of the first class function sample is higher than the second class function sample, the row of the second class function sample
Name is higher than the 3rd class function sample.
E29. a kind of computing device, including:Processor, memory, communication interface and communication bus, the processor, institute
State memory and the communication interface and mutual communication is completed by the communication bus;
The memory is used to deposit an at least executable instruction, and the executable instruction makes the computing device such as
Operated corresponding to the sample extraction method of source code function any one of A1-A9.
F30. a kind of computer-readable storage medium, an at least executable instruction is stored with the storage medium, it is described to hold
Row instruction makes operation corresponding to the sample extraction method of source code function of the computing device as any one of A1-A9.
G31. a kind of computing device, including:Processor, memory, communication interface and communication bus, the processor, institute
State memory and the communication interface and mutual communication is completed by the communication bus;
The memory is used to deposit an at least executable instruction, and the executable instruction makes the computing device such as
Operated corresponding to code search extracting method any one of B10-B14.
I32. a kind of computer-readable storage medium, an at least executable instruction is stored with the storage medium, it is described to hold
Row instruction makes operation corresponding to code search method of the computing device as any one of B10-B14.
Claims (10)
1. a kind of sample extraction method of source code function, including:
Obtain sound code file;
The sound code file is parsed, segmentation obtains at least one function file;
Extract the Function feature of at least one function file;
The function sample of essential information comprising at least one function file and Function feature is stored in Sample Storehouse.
2. according to the method for claim 1, wherein, the acquisition sound code file further comprises:
Sound code file is obtained from code storage.
3. a kind of code search method, methods described is obtained based on the method any one of foundation the claims 1-2
Sample Storehouse and perform, methods described includes:
Obtain code to be searched;
The code is parsed, extracts the characteristic value of the code;
According to the characteristic value of the code, in the sample library inquiry and the function sample of the code matches;
The function sample inquired is provided to front end page to be shown.
4. a kind of sample extraction device of source code function, including:
Source code acquisition module, suitable for obtaining sound code file;
Split module, suitable for parsing the sound code file, segmentation obtains at least one function file;
Function feature extraction module, suitable for extracting the Function feature of at least one function file;
Enter library module, suitable for the function sample of the essential information comprising at least one function file and Function feature is stored in
Sample Storehouse.
5. device according to claim 4, wherein, the source code acquisition module is further adapted for:
Sound code file is obtained from code storage.
6. a kind of code search device, including:
Code obtaining module, suitable for obtaining code to be searched;
Code characteristic extraction module, suitable for parsing the code, extract the characteristic value of the code;
Matching module, suitable for the characteristic value according to the code, in the sample library inquiry and the function sample of the code matches
This;
Display module, it is shown suitable for providing the function sample inquired to front end page.
7. a kind of computing device, including:Processor, memory, communication interface and communication bus, the processor, the storage
Device and the communication interface complete mutual communication by the communication bus;
The memory is used to deposit an at least executable instruction, and the executable instruction makes the computing device such as right will
Ask and operated corresponding to the sample extraction method of the source code function any one of 1-2.
8. a kind of computer-readable storage medium, an at least executable instruction, the executable instruction are stored with the storage medium
Make operation corresponding to the sample extraction method of source code function of the computing device as any one of claim 1-2.
9. a kind of computing device, including:Processor, memory, communication interface and communication bus, the processor, the storage
Device and the communication interface complete mutual communication by the communication bus;
The memory is used to deposit an at least executable instruction, and the executable instruction makes the computing device such as right will
Ask and operated corresponding to the code search extracting method described in 3.
10. a kind of computer-readable storage medium, an at least executable instruction, the executable instruction are stored with the storage medium
Make to operate corresponding to computing device code search method as claimed in claim 3.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710972003.5A CN107678968A (en) | 2017-10-18 | 2017-10-18 | Sample extraction method, apparatus, computing device and the storage medium of source code function |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710972003.5A CN107678968A (en) | 2017-10-18 | 2017-10-18 | Sample extraction method, apparatus, computing device and the storage medium of source code function |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107678968A true CN107678968A (en) | 2018-02-09 |
Family
ID=61141488
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710972003.5A Pending CN107678968A (en) | 2017-10-18 | 2017-10-18 | Sample extraction method, apparatus, computing device and the storage medium of source code function |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107678968A (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110389753A (en) * | 2019-06-06 | 2019-10-29 | 五八有限公司 | Chain type call method, device, electronic equipment and the storage medium of native applications |
CN110941726A (en) * | 2018-09-25 | 2020-03-31 | 福斯德公司 | Method for converting source code into digital identifier and comparing with data set |
US11138094B2 (en) | 2020-01-10 | 2021-10-05 | International Business Machines Corporation | Creation of minimal working examples and environments for troubleshooting code issues |
US11163592B2 (en) | 2020-01-10 | 2021-11-02 | International Business Machines Corporation | Generation of benchmarks of applications based on performance traces |
CN115238102A (en) * | 2022-06-28 | 2022-10-25 | 北京关键科技股份有限公司 | Code data feature extraction and retrieval method and device |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR101038397B1 (en) * | 2009-06-19 | 2011-06-01 | 강원대학교산학협력단 | Method for determining test alternation factor in robot software white box test and automated testing system |
CN102902629A (en) * | 2012-06-20 | 2013-01-30 | 华为技术有限公司 | Storage space mapping method and storage space mapping device |
CN103559025A (en) * | 2013-10-21 | 2014-02-05 | 沈阳建筑大学 | Software refactoring method through clustering |
CN103902543A (en) * | 2012-12-25 | 2014-07-02 | 华为技术有限公司 | Database inquiry method and device and database system |
CN105677306A (en) * | 2014-11-18 | 2016-06-15 | 中兴通讯股份有限公司 | Automation script compiling method and device |
CN106803040A (en) * | 2017-01-18 | 2017-06-06 | 腾讯科技(深圳)有限公司 | Virus signature processing method and processing device |
-
2017
- 2017-10-18 CN CN201710972003.5A patent/CN107678968A/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR101038397B1 (en) * | 2009-06-19 | 2011-06-01 | 강원대학교산학협력단 | Method for determining test alternation factor in robot software white box test and automated testing system |
CN102902629A (en) * | 2012-06-20 | 2013-01-30 | 华为技术有限公司 | Storage space mapping method and storage space mapping device |
CN103902543A (en) * | 2012-12-25 | 2014-07-02 | 华为技术有限公司 | Database inquiry method and device and database system |
CN103559025A (en) * | 2013-10-21 | 2014-02-05 | 沈阳建筑大学 | Software refactoring method through clustering |
CN105677306A (en) * | 2014-11-18 | 2016-06-15 | 中兴通讯股份有限公司 | Automation script compiling method and device |
CN106803040A (en) * | 2017-01-18 | 2017-06-06 | 腾讯科技(深圳)有限公司 | Virus signature processing method and processing device |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110941726A (en) * | 2018-09-25 | 2020-03-31 | 福斯德公司 | Method for converting source code into digital identifier and comparing with data set |
CN110389753A (en) * | 2019-06-06 | 2019-10-29 | 五八有限公司 | Chain type call method, device, electronic equipment and the storage medium of native applications |
CN110389753B (en) * | 2019-06-06 | 2024-01-23 | 五八有限公司 | Chained calling method and device of native application, electronic equipment and storage medium |
US11138094B2 (en) | 2020-01-10 | 2021-10-05 | International Business Machines Corporation | Creation of minimal working examples and environments for troubleshooting code issues |
US11163592B2 (en) | 2020-01-10 | 2021-11-02 | International Business Machines Corporation | Generation of benchmarks of applications based on performance traces |
CN115238102A (en) * | 2022-06-28 | 2022-10-25 | 北京关键科技股份有限公司 | Code data feature extraction and retrieval method and device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107678968A (en) | Sample extraction method, apparatus, computing device and the storage medium of source code function | |
CN106131071B (en) | A kind of Web method for detecting abnormality and device | |
JP7131199B2 (en) | Automatic identification of related software projects for cross-project learning | |
CN110348214B (en) | Method and system for detecting malicious codes | |
CN103778205B (en) | A kind of commodity classification method and system based on mutual information | |
CN104715064B (en) | It is a kind of to realize the method and server that keyword is marked on webpage | |
US9104709B2 (en) | Cleansing a database system to improve data quality | |
CN105205397A (en) | Rogue program sample classification method and device | |
US11263062B2 (en) | API mashup exploration and recommendation | |
CN112307374A (en) | Jumping method, device and equipment based on backlog and storage medium | |
CN107784003B (en) | Data query anomaly detection method, device, equipment and system | |
CN106469144A (en) | Text similarity computing method and device | |
JP2016085697A5 (en) | ||
CN112200196A (en) | Phishing website detection method, device, equipment and computer readable storage medium | |
CN105790967B (en) | Network log processing method and device | |
EP2538322A1 (en) | Systems and methods for inter-object pattern matching | |
US9916284B2 (en) | Analyzing document content and generating an appendix | |
CN114564624A (en) | Feature matching rule construction method, feature matching device, feature matching equipment and feature matching medium | |
US20180011870A1 (en) | Method and system for compressing genome sequences using graphic processing units | |
TW201818268A (en) | Webpage data extraction device and webpage data extraction method thereof | |
CN103678601A (en) | Model essay retrieval request processing method and device | |
US11574053B1 (en) | System and method for detecting malicious scripts | |
KR102021383B1 (en) | Method and apparatus for analyzing program by associating dynamic analysis with static analysis | |
CN105550335A (en) | Method and device for providing search abstract embedded with resource downloading information | |
KR102474042B1 (en) | Method for analyzing association of diseases using data mining |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20180209 |
|
RJ01 | Rejection of invention patent application after publication |