Myth or Reality? Analyzing the Effect of Design Patterns on Software Maintainability

Abstract

Although the belief of utilizing design patterns to create better quality software is fairly widespread, there is relatively little research objectively indicating that their usage is indeed beneficial. In this paper we try to reveal the connection between design patterns and software maintainability. We analyzed more than 300 revisions of JHotDraw, a Java GUI framework whose design relies heavily on some well-known design patterns. We used our probabilistic quality model for estimating the maintainability and we parsed the javadoc annotations of the source code for gathering the pattern instances. We found that every introduced pattern instance caused an improvement in the different quality attributes. Moreover, the average design pattern line density showed a very high, 0.89 Pearson correlation with the estimated maintainability values. Although the amount of available empirical data is still very small, these first results suggest that the usage of design patterns do improve code maintainability.

Publication
Proceedings of the 2012 International Conference on Advanced Software Engineering & Its Applications (ASEA 2012), Jeju Island, Korea, Pages 138–145

BibTeX:

@InProceedings{HBF12,
    author    = {Heged{\H{u}}s, P{\'e}ter and B{\'a}n, D{\'e}nes and Ferenc, Rudolf and Gyim{\'o}thy, Tibor},
    title     = {Myth or Reality? Analyzing the Effect of Design Patterns on Software Maintainability},
    booktitle = {Proceedings of the 2012 International Conference on Advanced Software Engineering \& Its Applications (ASEA 2012)},
    year      = {2012},
    volume    = {340},
    series    = {Communications in Computer and Information Science (CCIS)},
    pages     = {138--145},
    address   = {Jeju Island, Korea},
    month     = nov,
    publisher = {Springer-Verlag},
    doi       = {10.1007/978-3-642-35267-6_18},
    keywords  = {Design patterns, Software maintainability, Empirical validation, OO design},
    url       = {https://link.springer.com/chapter/10.1007%2F978-3-642-35267-6_18},
}