http:// an approach to measure java code quality in reuse environment master: aline timóteo...
Post on 13-Dec-2015
216 Views
Preview:
TRANSCRIPT
http://www.rise.com.br
An Approach to Measure Java Code An Approach to Measure Java Code Quality in Reuse EnvironmentQuality in Reuse Environment
Master: Aline TimóteoMaster: Aline TimóteoProfessor: Silvio MeiraProfessor: Silvio Meira
UFPE – Federal University of PernambucoUFPE – Federal University of Pernambucoalt@cin.ufpe.bralt@cin.ufpe.br
http://www.rise.com.br
SummarySummary
Motivation Background
Quality in a Reuse Environment Metrics
An Approach to Measure Java Code Quality Main Contributions
http://www.rise.com.br
MotivationMotivation
http://www.rise.com.br
MotivationMotivation
Reuse environment [Frakes, 1994] Process Metrics Assets Tools
http://www.rise.com.br
MotivationMotivation
Component Repository promote reuse success [Griss, 1994]
Search Engine[Garcia, 2006] Analyze a set of Search Engines
Requirements Artifact filtering
http://www.rise.com.br
ProblemProblem
Artifacts quality In search time? How to eliminate low-quality artifacts?
In other words…
How to eliminate low-quality artifacts in search time?
http://www.rise.com.br
BackgroundBackground
http://www.rise.com.br
Quality in a Reuse Environment Quality in a Reuse Environment [Etzkorn, 2001][Etzkorn, 2001] ISO 9126
http://www.rise.com.br
MetricsMetrics
“Software metrics is a method to quantify attributes in software processes, products and projects” [Daskalantonakis, 1992]
Metrics Timeline
Age 1: before 1991, where the main focus was on metrics based on the code complexity
Age 2: after 1992, where the main focus was on metrics based on the concepts of Object Oriented (OO) systems
http://www.rise.com.br
Age 1: Complexity Age 2: Object Oriented
Most Referenced MetricsMost Referenced Metrics
LOC
Cyclomatic Complexity [McCabe, 1976]
Chidamber and Kemerer Metrics [Chidamber, 1994]
Lorenz and Kidd Metrics [Lorenz, 1994]
MOOD Metrics [Brito, 1994]
http://www.rise.com.br
Problems related to Metrics Problems related to Metrics [Ince, 1988 and Briand, 2002][Ince, 1988 and Briand, 2002] Metrics Validation
Measurement goal Experimental hypothesis Environment or context Theoretical Validation Empirical validation
Metrics Automation Different set of metrics implemented Bad documentation Quality attributes x Metrics
http://www.rise.com.br
http://www.rise.com.br
An Approach to An Approach to Measure Java Code Measure Java Code
QualityQuality
http://www.rise.com.br
An Approach to Measure Java Code QualityAn Approach to Measure Java Code Quality
Quality Attributes x Metrics
Metrics Selection and Specification
Quality Attributes measurement
http://www.rise.com.br
Quality Attributes x MetricsQuality Attributes x Metrics
Quality Attributes Code Attributes LOC Cyclomatic Complexity CK Metrics
WMC DIT NOC CBO RFC LCOM
size x
Analysability complexty x x x X X
documentation x
complexity x x x X X
modularity/
encapsulation X
Changeability coupling x X
cohesion X
inheritance x
Stability
Testability complexity x x x X X
coupling x X
complexidade x x x X x
documentation x
Reusabilitymodularity/
encapsulation x
coupling X x
cohesion x
Quality Attributes x MetricsQuality Attributes x Metrics
http://www.rise.com.br
Quality Attributes Code Attributes Lorenz and Kidd
PIM NIM NIV NCM NCV NMO NMI NMA SIX APPM
Analysability
size x x x x x
complexty
documentation
Changeability
complexity
modularity/ encapsulation
coupling
cohesion
inheritance x x x x
Stability
Testability
complexity
coupling
Reusability
complexidade
documentation
modularity/ encapsulation
coupling
cohesion
Quality Attributes x MetricsQuality Attributes x Metrics
http://www.rise.com.br
Quality Attributes Code Attributes MOOD Metrics
MHF AHF MIF AIF PF
Analysability
size
complexty
documentation
Changeability
complexity
modularity/ encapsulation
coupling
cohesion
inheritance x x
Stability
Testability
complexity
coupling
Reusability
complexity
documentation
modularity/ encapsulation
coupling
cohesion
http://www.rise.com.br
Metrics Selection and SpecificationMetrics Selection and Specification
- Theoretical Validation
- Empirical Validation
- Tools
-LOC
-Cyclomatic Complexity
- CK Metrics
Metrics Selection and SpecificationMetrics Selection and Specification
http://www.rise.com.br
Quality Attributes Measurement (QAM)Quality Attributes Measurement (QAM)
QAM = (the number of metrics that have a allowable value)
QAM >= Number of metrics /2
Example:
2,5 <= QAM <= 5
http://www.rise.com.br
Quality Attribute
Code Attribute CK Metrics
WMC DIT CBO RFC LCOMTestability
complexity x x x x
coupling x x
http://www.rise.com.br
ContributionsContributions
Introduce quality analysis in a search engine Store assets and their quality attributes In the search time the asset is recovered according quality
attribute values
Quality attributes x Code metrics ISO 9126
http://www.rise.com.br
Current StageCurrent Stage
Sate-of-the-art in Software Metrics
Approach definition
Prototypal Implementation (partial)
Integration with B.A.R.T. (next step)
Experiment (next step)
http://www.rise.com.br
ReferênciasReferê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.
http://www.rise.com.br
Aline TimóteoAline Timóteo
UFPE – Federal University of PernambucoUFPE – Federal University of Pernambuco
alt.timoteo@gmail.comalt.timoteo@gmail.com
top related