Presentation is loading. Please wait.

Presentation is loading. Please wait.

An Approach to Measure Java Code Quality in Reuse Environment Aline Timóteo Advisor: Silvio Meira Co-advisor: Eduardo Almeida UFPE.

Similar presentations


Presentation on theme: "An Approach to Measure Java Code Quality in Reuse Environment Aline Timóteo Advisor: Silvio Meira Co-advisor: Eduardo Almeida UFPE."— Presentation transcript:

1 http://www.rise.com.br An Approach to Measure Java Code Quality in Reuse Environment Aline Timóteo Advisor: Silvio Meira Co-advisor: Eduardo Almeida UFPE – Federal University of Pernambuco alt@cin.ufpe.br 1

2 http://www.rise.com.br Summary Motivation An Approach to Measure Java Code Quality Main Contributions Status An Approach to Measure Java Code Quality in a Reuse Environment 2

3 http://www.rise.com.br Motivation 3

4 Motivation Reuse is a competitive advantage  Quality  Coust An Approach to Measure Java Code Quality in a Reuse Environment 4

5 http://www.rise.com.br Problem Component Repository promote reuse success [Griss, 1994] Artifacts quality must be assured by the organization that maintains a repository? [Seacord, 1999]  Many version of a component on the repository  Lack of context How to minimize low-quality artifacts reuse? An Approach to Measure Java Code Quality in a Reuse Environment 5

6 http://www.rise.com.br An Approach to Measure Java Code Quality 6

7 http://www.rise.com.br An Approach to Measure Java Code Quality Quality Metrics Selection Quality Attributes measurement An Approach to Measure Java Code Quality in a Reuse Environment 7

8 http://www.rise.com.br Quality in a Reuse Environment [Etzkorn, 2001] ISO 9126 An Approach to Measure Java Code Quality in a Reuse Environment 8

9 http://www.rise.com.br Quality Attributes x Metrics Quality Attributes Code Attributes LOC Cyclomatic Complexity CK Metrics WMCDITNOCCBORFCLCOM sizex Analyzabilitycomplexity xxx XX documentationx complexity xxx XX modularity/ encapsulation X Changeabilitycoupling x X cohesion X inheritance x Stability Testabilitycomplexity xxx XX coupling x X complexity xxx Xx documentationx Reusability modularity/ encapsulation x coupling X x cohesion x An Approach to Measure Java Code Quality in a Reuse Environment 9

10 Metrics Selection Applicable for Java Empirical Validation Theoretical Validation Acceptance http://www.rise.com.br An Approach to Measure Java Code Quality in a Reuse Environment 10

11 Metrics Selection McCabe Metric [McCabe, 1976]  Theoretical Validation, according to graphs theory  Independence of technology  Empirical Validation  Acceptance [Refactorit, 2001; Metrics, 2005; JHawk, 2007] http://www.rise.com.br An Approach to Measure Java Code Quality in a Reuse Environment 11

12 Metrics Selection CK Metrics [Chidamber, 1994],  Theoretical Validation,  Developed in a OO context  Empirical Validation [Briand, 1994; Chidamber, 1998; Tang, 1999].  Acceptance [Refactorit, 2001; Metrics, 2005; JHawk, 2007] http://www.rise.com.br An Approach to Measure Java Code Quality in a Reuse Environment 12

13 Metrics Specification http://www.rise.com.br Response for a Class Definition Short nameRFC Description The response set of a class is a set of methods that can potentially be executed in response to a message received by an object of that class. Calculated by RFC = M + R M = number of methods in the class R = number of remote methods directly called by methods of the class Allowable valueRFC<=50 PrivateNo Analysis PresentationN/A Range of analysisWhen the development cycle is done Analysis procedureIdentify how classes have a highest responsibility ResponsibleMetrics Analyst An Approach to Measure Java Code Quality in a Reuse Environment 13

14 Quality Attributes Measurement (QAM) QAM = (the number of metrics that have a allowable value)  Heuristically QAM >= Number of metrics /2 Example: 2,5 <= QAM <= 5 http://www.rise.com.br Quality Attribute Code Attribute CK Metrics WMCDITCBORFCLCOM Testability complexityxx xx coupling x x Max Testability = 5 Min Testability = 2,5 An Approach to Measure Java Code Quality in a Reuse Environment 14

15 Automation http://www.rise.com.br An Approach to Measure Java Code Quality in a Reuse Environment 15

16 Experiment http://www.rise.com.br Java Class Stored Class Generate Class´s measurement Java Class with metrics metadata Recover class request Good quality Class An Approach to Measure Java Code Quality in a Reuse Environment 16

17 Experiment Main Question  The retrieval component quality is better? Compare B.A.R.T. search results  Results before introduce filter  Results after introduce filter Apply questionnaire for customers http://www.rise.com.br An Approach to Measure Java Code Quality in a Reuse Environment 17

18 http://www.rise.com.br Main Contributions Introduce quality analysis in a repository  Reduce code problem propagation  Highest Reliability... An Approach to Measure Java Code Quality in a Reuse Environment 18

19 http://www.rise.com.br Current Stage An Approach to Measure Java Code Quality in a Reuse Environment 19

20 http://www.rise.com.br Referências [Frakes, 1994] W. B. Frakes and S. Isoda, "Success Factors of Systematic Software Reuse," IEEE Software, vol. 11, pp. 14--19, 1994. [Griss, 1994] M. L. Griss, "Software Reuse Experience at Hewlett-Packard," presented at 16th International Conference on Software Engineering (ICSE), Sorrento, Italy, 1994. [Garcia, 2006] V. C. Garcia, D. Lucrédio, F. A. Durão, E. C. R. Santos, E. S. Almeida, R. P. M. Fortes, and S. R. L. Meira, "From Specification to Experimentation: A Software Component Search Engine Architecture," presented at The 9th International Symposium on Component-Based Software Engineering (CBSE 2006), Mälardalen University, Västerås, Sweden, 2006. [Etzkorn, 2001] Letha H. Etzkorn, William E. Hughes Jr., Carl G. Davis: Automated reusability quality analysis of OO legacy software. Information & Software Technology 43(5): 295-308 (2001) [Daskalantonakis, 1992] M. K. Daskalantonakis, “A Pratical View of Software Measurement and Implementation Experiences Within Motorola”, IEEE Transactions on Software Engineering, vol 18, 1992, pp. 998–1010. [McCabe, 1976] T. J. McCabe, “A Complexity Measure”. IEEE Transactions of Software Engineering, vol SE-2, 1976, pp. 308-320. [Chidamber, 1994] S. R. Chidamber, C. F. Kemerer, “A Metrics Suite for Object Oriented Design”, IEEE Transactions on Software Engineering, vol 20, Piscataway - USA, 1994, pp. 476-493. [Lorenz, 1994] M. Lorenz, J. Kidd, “Object-Oriented Software Metrics: A Practical Guide”, Englewood Cliffs, New Jersey - USA, 1994. [Brito, 1994] A. F. Brito, R. Carapuça, "Object-Oriented Software Engineering: Measuring and controlling the development process", 4th Interntional Conference on Software Quality, USA, 1994. [Ince, 1988] D. C. Ince, M. J. Sheppard, "System design metrics: a review and perspective", Second IEE/BCS Conference, Liverpool - UK, 1988, pp. 23-27. [Briand, 2002] L. C. Briand, S. Morasca, V. R. Basili, “An Operational Process for Goal-Driven Definition of Measures”, Software Engineering - IEEE Transactions, vol 28, 2002, pp. 1106-1125. [Morasca, 1989] S. Morasca, L. C. Briand, V. R. Basili, E. J. Weyuker, M. V. Zelkowitz, B. Kitchenham, S. Lawrence Pfleeger, N. Fenton, "Towards a framework for software measurementvalidation", Software Engineering, IEEE Transactions, vol 23, 1995, pp. 187-189. [Seacord, 1999] Robert C. Seacord. Software engineering component repositories. Technical report, Software Engineering Institute (SEI), 1999 An Approach to Measure Java Code Quality in a Reuse Environment 20

21 [Refactorit, 2001] Refactorit tool, online, last update: 01/2008, available: http://www.aqris.com/display/ap/RefactorIt http://www.aqris.com/display/ap/RefactorIt [Jdepend, 2005] JDepend tool, online, last update: 03/2006,available: http://www.clarkware.com/software/JDepend.html http://www.clarkware.com/software/JDepend.html [Metrics, 2005] Metrics Eclipse Plugin, online, last update: 07/2005, available: http://sourceforge.net/projects/metrics http://sourceforge.net/projects/metrics [Jhawk, 2007] JHawk Eclipse Plugin, online, last update: 03/2007, available: http://www.virtualmachinery.com/jhawkprod.htm http://www.virtualmachinery.com/jhawkprod.htm http://www.rise.com.br An Approach to Measure Java Code Quality in a Reuse Environment 21

22 http://www.rise.com.br Aline Timóteo UFPE – Federal University of Pernambuco alt.timoteo@gmail.com 22


Download ppt "An Approach to Measure Java Code Quality in Reuse Environment Aline Timóteo Advisor: Silvio Meira Co-advisor: Eduardo Almeida UFPE."

Similar presentations


Ads by Google