发明名称 Exception based quality assessment
摘要 The embodiments may include an apparatus for measuring code quality using exceptions. The apparatus may include a runtime collector configured to intercept exceptions generated by an application, and collect exception information for each exception, during runtime of the application, based on instrumentation code included within the application. The apparatus may include a collection module configured to store the intercepted exceptions and corresponding exception information in a memory unit, an exception analyzer configured to analyze the intercepted exceptions based on the collected exception information stored in the memory unit, and a report generator configured to generate at least one report based on the analysis. The at least one report may provide an indication of code quality of the application.
申请公布号 US9052980(B2) 申请公布日期 2015.06.09
申请号 US201313772040 申请日期 2013.02.20
申请人 BMC SOFTWARE, INC. 发明人 Hulick, Jr. Walter T.
分类号 G06F9/44 主分类号 G06F9/44
代理机构 Brake Hughes Bellermann LLP 代理人 Brake Hughes Bellermann LLP
主权项 1. A method for measuring code quality using exceptions, the method comprising: intercepting, by at least one processor, exceptions generated by an application, and collecting, by the at least one processor, exception information for each exception, during runtime of the application, based on instrumentation code included within the application, each exception representing a potential error that occurred during runtime of the application, the exceptions including caught exceptions and uncaught exceptions; storing, by the at least one processor, the intercepted exceptions and corresponding exception information in a memory unit; analyzing, by the at least one processor, the intercepted exceptions based on the collected exception information stored in the memory unit including determining a total number of intercepted exceptions, a number of uncaught exceptions, and a number of unique locations that produced the exceptions; calculating, by the at least one processor, a score indicating a level of code quality of the application with a weighted scoring algorithm inputted with the total number of intercepted exceptions, the number of uncaught exceptions, and the number of unique locations that produced the exceptions, wherein the calculating the score with the weighted scoring algorithm includes applying weights to values of the collected exception information; and generating, by the at least one processor, an exception-based report providing the score, and a listing of the exceptions by type, the listing of the exceptions also indicating whether or not an exception was uncaught and number of times each exception type was thrown.
地址 Houston TX US