Font Size: a A A

A Declarative Code Query Technology For Heterogeneous Code Repositories

Posted on:2015-01-02Degree:MasterType:Thesis
Country:ChinaCandidate:Y HeFull Text:PDF
GTID:2308330482979048Subject:Computer technology
Abstract/Summary:PDF Full Text Request
In recent years, with the popularization of the Internet and the rapid progress of software industry, a variety of open source code repository and the software community have also sprung up, people can easily acquire lots of projects or source code through the network, for learning, consulted and reuse. However, code query in these open source communities still stays at the level of keywords matching, and the semantics of the source code cannot be fully reflected and used, how to do code query at the semantic level more effectively becomes a problem which is badly in need of solution. In addition, due to different open source repositories usually follow different access and control protocol, code repositories tend to be heterogeneous, it is need to provide an effective means to support the semantic level query in these heterogeneous code repositories.To solve above problems, we put forward a declarative code query method for heterogeneous code repositories. We build an unified platform based on open source database MySQL and store code information collected from heterogeneous code repositories in an unified data structure. At the same time, a richly semantic code query language JSQL is designed to support code query at the semantic level, and based on this platform, we also realize an corresponding engine to help execute the JSQL query command. The specific method is as follows:·In view of the heterogeneous code repositories, how to access the source code information. We design the storage form for source code information, all the source code will be parsed and deposited in the unified tables in relational database. Code query process is only based on the relational database, and has nothing to do with a specific code repository.· How to describe these requirements for code query. We define a declarative code query language JSQL, whose syntax is simple, but powerful. What’s more, it can support the query for program elements such as class, interface, method, object and statement. And at the semantic level, the description of attribute and relation conditions is supplied, and can be composed to a complex semantic condition through the logical operators and predicates.· In view of the code query process, how to ensure the query efficiency. We have designed a code query engine, it can convert JSQL commands to s-tandard SQL commands and executed. In addition, we also improve the query efficiency through the index establishment, SQL optimization and other database technologies.
Keywords/Search Tags:Code Query, Heterogeneous Source Repository, Code Query Lan- guage, Relational Database
PDF Full Text Request
Related items