Hani Abdeen | University of Montreal (original) (raw)

Papers by Hani Abdeen

Research paper thumbnail of Learning Dependency-based Change Impact Predictors using Independent Change Histories

Information and Software Technology, 2015

Research paper thumbnail of Mining Multi-level API Usage Patterns

2015 IEEE 22nd International Conference on Software Analysis, Evolution, and Reengineering (SANER), 2015

Software developers need to cope with complexity of Application Programming Interfaces (APIs) of ... more Software developers need to cope with complexity of Application Programming Interfaces (APIs) of external libraries or frameworks. However, typical APIs provide several thousands of methods to their client programs, and such large APIs are difficult to learn and use. An API method is generally used within client programs along with other methods of the API of interest. Despite this, co-usage relationships between API methods are often not documented. We propose a technique for mining Multi-Level API Usage Patterns (MLUP) to exhibit the co-usage relationships between methods of the API of interest across interfering usage scenarios. We detect multi-level usage patterns as distinct groups of API methods, where each group is uniformly used across variable client programs, independently of usage contexts. We evaluated our technique through the usage of four APIs having up to 22 client programs per API. For all the studied APIs, our technique was able to detect usage patterns that are, almost all, highly consistent and highly cohesive across a considerable variability of client programs.

Research paper thumbnail of Type Variability and Completeness of Interfaces in Java Applications

ABSTRACT Interfaces are widely used as central design elements of Java applications. Although int... more ABSTRACT Interfaces are widely used as central design elements of Java applications. Although interfaces are abstract types similar to abstract classes, the usage of interfaces in Java applications may considerably differ from the usage of abstract classes. Unlike abstract classes, interfaces are meant to enable multiple inheritance in Java programs. Hence, interfaces are meant to encode shared similarities between classes belonging to different class-type hierarchies. Therefore, it is frequent to use interfaces as partial types, where an interface specifies one specific aspect or usage of its implementing classes. In this paper, we investigate interfaces' usage in Java applications from two perspectives. First, we investigate the usage of interfaces as types of classes belonging to different class-type hierarchies (i.e., interface's type variability). Second, we investigate the usage of interfaces as partial types of implementing classes (i.e., interface's type completeness).

Research paper thumbnail of The Package Blueprint: Visually analyzing and quantifying packages dependencies

Science of Computer Programming, 2014

ABSTRACT Large object-oriented applications are structured over many packages. Packages are impor... more ABSTRACT Large object-oriented applications are structured over many packages. Packages are important but complex structural entities that are difficult to understand since they act as containers of classes, which can have many dependencies with other classes spread over multiple packages. However to be able to take decisions (e.g. refactoring and/or assessment decisions), maintainers face the challenges of managing (sorting, grouping) the massive amount of dependencies between classes spread over multiple packages. To help maintainers, there is a need for at the same time understanding, and quantifying, dependencies between classes as well as understanding how packages as containers of such classes depend on each other. In this paper, we present a visualization, named Package Blueprint, that reveals in detail package internal structure, as well as the dependencies between an observed package and its neighbors, at both package and class levels. Package Blueprintaims at assisting maintainers in understanding package structure and dependencies, in particular when they focus on few packages and want to take refactoring decisions and/or to assess the structure of those packages. A package blueprint is a space filling matrix-based visualization, using two placement strategies that are enclosure and adjacency. Package blueprint is structured around the notion of surfaces that group classes and their dependencies by their packages (i.e., enclosure placement); whilst surfaces are placed next to their parent node which is the package under-analysis (i.e., adjacency placement). We present two views: one stressing how an observed package depends upon the rest of the system and another stressing how the system depends upon that package. To evaluate the contribution of package blueprint for understanding packages we performed an exploratory user study comparing package blueprint with an advanced IDE. The results shows that users of package blueprint are faster in analyzing and assessing package structure. The results are proved statically significant and they show that package blueprint considerably improve the experience of standard browser users.

Research paper thumbnail of Software metric for Java and C++ practices (Workpackage 1.1)

Research paper thumbnail of Multi-Objective Optimization in Rule-Based Design Space Exploration

Design space exploration (DSE) aims to find optimal design candidates of a domain with respect to... more Design space exploration (DSE) aims to find optimal design candidates of a domain with respect to different objectives where design candidates are constrained by complex structural and numerical restrictions.
Rule-based DSE aims to find such candidates that are reachable from an initial model by applying a sequence of exploration rules. Solving a rule-based DSE problem is a difficult challenge due to the inherently dynamic nature of the problem.

In the current paper, we propose to integrate multi-objective optimization techniques by using Non-dominated Sorting Genetic Algorithms (NSGA) to drive rule-based design space exploration. For this purpose, finite populations of the most promising design candidates are maintained wrt. different optimization criteria. In our context, individuals of a generation are defined as a sequence of rule applications leading from an initial model to a candidate model. Populations evolve by mutation and crossover operations which manipulate (change, extend or combine) rule execution sequences to yield new individuals.

Our multi-objective optimization approach for rule-based DSE is domain independent and it is automated by tooling built on the Eclipse framework. The main added value is to seamlessly lift multi-objective optimization techniques to the exploration process preserving both domain independence and a high-level of abstraction. Design candidates will still be represented as models and the evolution of these models as rule execution sequences. Constraints are captured by model queries while objectives can be derived both from models or rule applications.

Research paper thumbnail of How We Design Interfaces, and How to Assess It

Interfaces are widely used in Java applications as central design elements for modular programmin... more Interfaces are widely used in Java applications as central design elements for modular programming to increase program reusability and to ease maintainability of software systems. Despite the importance of interfaces and a considerable research effort that has investigated code quality and concrete classes' design, few works have investigated interfaces' design. In this paper, we empirically study interfaces' design and its impact on the design quality of implementing classes (i.e., class cohesion) analyzing twelve Java object-oriented applications. In this study we propose the "Interface-Implementations Model" that we use to adapt class cohesion metrics to assess the cohesion of interfaces based on their implementations. Moreover, we use other metrics that evaluate the conformance of interfaces to the well-known design principles "Program to an Interface, not an implementation" and "Interface Segregation principle". The results show that software developers abide well by the interface design principles cited above, but they neglect the cohesion property. The results also show that such design practices of interfaces lead to a degraded cohesion of implementing classes, where these latter would be characterized by a worse cohesion than other classes.

Research paper thumbnail of Towards Automatically Improving Package Structure While Respecting Original Design Decisions

"Recently, there has been an important progress in applying search-based optimization techniques ... more "Recently, there has been an important progress in applying search-based optimization techniques to the problem of
software remodularization. Yet, a major part of the existing body
of work addresses the problem of modularizing software systems
from scratch, regardless of the existing packages structure. This
paper presents a novel multi-objective optimization approach
for improving existing packages structure. The optimization approach aims at increasing the cohesion and reducing the coupling and cyclic connectivity of packages, by modifying as less as possible the existing packages organization. Moreover, maintainers can specify several constraints to guide the optimization process with regard to extra design factors. To this contribution, we use the Non-Dominated Sorting Genetic Algorithm (NSGA-II).
We evaluate the optimization approach through an experiment
covering four real-world software systems. The results promise
the effectiveness of our optimization approach for improving
existing packages structure by doing very small modifications."

Keywords: Software Modularization, Package Structure Quality, Package Structure Metrics, Remodularization

Research paper thumbnail of Modularization Metrics: Assessing Package Organization in Legacy Large Object-Oriented Software

There exist many large object-oriented software systems consisting of several thousands of classe... more There exist many large object-oriented software systems consisting of several thousands of classes that are organized into several hundreds of packages. In such software systems, classes cannot be considered as units for software modularization. In such context, packages are not simply classes containers, but they also play the role of modules: a package should focus to provide well identified services to the rest of the software system. Therefore, understanding and assessing package organization is primordial for software maintenance tasks. Although there exist a lot of works proposing metrics for the quality of a single class and/or the quality of inter-class relationships, there exist few works dealing with some aspects for the quality of package organization and relationship. We believe that additional investigations are required for assessing package modularity aspects. The goal of this paper is to provide a complementary set of metrics that assess some modularity principles for packages in large legacy object-oriented software: Information-Hiding, Changeability and Reusability principles. Our metrics are defined with respect to object-oriented dependencies that are caused by inheritance and method call. We validate our metrics theoretically through a careful study of the mathematical properties of each metric.

Keywords: Software Modularization, Package Structure Quality, Package Structure Metrics

Research paper thumbnail of Package Reference Fingerprint: a Rich and Compact Visualization to Understand Package Relationships

Object-oriented languages such as Java, Smalltalk, and C++ structure their programs using package... more Object-oriented languages such as Java, Smalltalk, and C++ structure their programs using packages, allowing classes to be organized into named abstractions. Maintainers of large applications need to understand how packages are structured and how they relate to each other, but this task is very complex because packages often have multiple clients and different roles (class container, code ownership...). Cohesion and coupling are still among the most used metrics, because they help identify candidate packages for restructuring; however, they do not help maintainers understand the structure and interrelationships between packages. In this paper, we present the package fingerprint, a 2D visualization of the references made to and from a package. The proposed visualization offers a semantically rich, but compact and zoomable visualization centered on packages. We focus on two views (incoming and outgoing references) that help users understand how the package under analysis is used by the system and how it uses the system. We applied these views on three large case studies: JBoss, Azureus, and ArgoUML.

Research paper thumbnail of Package Fingerprints: A visual summary of package interface usage

Information & Software Technology, 2010

Context: Object-oriented languages such as Java, Smalltalk, and C++ structure their programs usin... more Context: Object-oriented languages such as Java, Smalltalk, and C++ structure their programs using packages. Maintainers of large systems need to understand how packages relate to each other, but this task is complex because packages often have multiple clients and play different roles (class container, code ownership. . . ). Several approaches have been proposed, among which the use of cohesion and coupling metrics. Such metrics help identify candidate packages for restructuring; however, they do not help maintainers actually understand the structure and interrelationships between packages.

Research paper thumbnail of Package Surface Blueprints: Visually Supporting the Understanding of Package Relationships

Large object-oriented applications are structured over large number of packages. Packages are imp... more Large object-oriented applications are structured over large number of packages. Packages are important but complex structural entities that may be difficult to understand since they play different development roles (i.e., class containers, code ownership basic structure, architectural elements...). Maintainers of large applications face the problem of understanding how packages are structured in general and how they relate to each others. In this paper, we present a compact visualization, named Package Surface Blueprint, that qualifies the relationships that a package has with its neighbours. A Package Surface Blueprint represents packages around the notion of package surfaces: groups of relationships according to the packages they refer to. We present two specific views one stressing the references made by a package and another showing the inheritance structure of a package. We applied the visualization on two large case studies: ArgoUML and Squeak.

Research paper thumbnail of Automatic Package Coupling and Cycle Minimization

Object-oriented (OO) software is usually organized into subsystems using the concepts of package ... more Object-oriented (OO) software is usually organized into subsystems using the concepts of package or module. Such modular structure helps applications to evolve when facing new requirements. However, studies show that as software evolves to meet requirements and environment changes, modularization quality degrades. To help maintainers improve the quality of software modularization we have designed and implemented a heuristic search-based approach for automatically optimizing inter-package connectivity (i.e., dependencies). In this paper, we present our approach and its underlying techniques and algorithm. We show through a case study how it enables maintainers to optimize OO package structure of source code. Our optimization approach is based on Simulated Annealing technique.

Research paper thumbnail of Automatic Package Coupling and Cycle Minimization

Object-oriented (OO) software is usually organized into subsystems using the concepts of package ... more Object-oriented (OO) software is usually organized into subsystems using the concepts of package or module. Such modular structure helps applications to evolve when facing new requirements. However, studies show that as software evolves to meet requirements and environment changes, modularization quality degrades. To help maintainers improve the quality of software modularization we have designed and implemented a heuristic search-based approach for automatically optimizing inter-package connectivity (i.e., dependencies). In this paper, we present our approach and its underlying techniques and algorithm. We show through a case study how it enables maintainers to optimize OO package structure of source code. Our optimization approach is based on Simulated Annealing technique.

Research paper thumbnail of CHARACTERIZING AND EVALUATING THE IMPACT OF SOFTWARE INTERFACE CLONES

Interfaces, if well designed, significantly reduce software complexity and ease maintainability. ... more Interfaces, if well designed, significantly reduce software complexity and ease maintainability. However, as software evolves, the organization and the quality of software interfaces gradually deteriorate. As a consequence, this often leads to increased development cost, lower code quality and reduced reusability.

Research paper thumbnail of Package Fingerprints: a visual summary of package interface usage Hani Abdeena , St´ephane Ducassea

Context: Object-oriented languages such as Java, Smalltalk, and C++ structure their programs usin... more Context: Object-oriented languages such as Java, Smalltalk, and C++ structure their programs using packages. Maintainers of large systems need to understand how packages relate to each other, but this task is complex because packages often have multiple clients and play different roles (class container, code ownership. . . ). Several approaches have been proposed, among which the use of cohesion and coupling metrics. Such metrics help identify candidate packages for restructuring; however, they do not help maintainers actually understand the structure and interrelationships between packages.

Research paper thumbnail of Metrics for Assessing The Design of Software Interfaces

Recent studies have largely investigated the detection of class design anomalies. They proposed a... more Recent studies have largely investigated the detection of class design anomalies. They proposed a large set of metrics that help in detecting those anomalies and in predicting the quality of class design. While those studies and the proposed metrics are valuable, they do not address the particularities of software interfaces. Interfaces define the contracts that spell out how software modules and logic units interact with each other. This paper proposes a list of design defects related to interfaces: shared similarity between interfaces, interface clones and redundancy in interface hierarchy. We identify and describe those design defects through real examples, taken from well-known Java applications. Then we define three metrics that help in automatically estimating the interface design quality, regarding the proposed design anomalies, and identify refactoring candidates. We investigate our metrics and show their usefulness through an empirical study conducted on three large Java applications.

Research paper thumbnail of Software Interfaces: On The Impact of Interface Design Anomalies

Interfaces are recognized as an important mechanism to define contracts governing interactions be... more Interfaces are recognized as an important mechanism to define contracts governing interactions between semiindependent software modules. Well-designed interfaces significantly reduce software complexity and ease maintainability by fostering modularization, hiding implementation details and minimizing the impact caused by changes in the software implementation. However, designing good interfaces is not a trivial task. The presence of interface design defects often yield increased development cost, lower code quality and reduced development productivity. Despite their importance, currently there are only a few research efforts that investigate the quality of interface design. In this paper, we identify and characterize common interface design anomalies and illustrate them via examples taken from well-known open source applications. In order to quantify the presence of interface design anomalies and estimate their impact on the interface design quality, as well on the software quality attributes, such as maintainability, we conduct an empirical study covering 9 open source projects. Building on our empirical results, we develop a set of recommendations to improve interface design.

Thesis Chapters by Hani Abdeen

Research paper thumbnail of Visualizing, Assessing and Re-Modularizing Object-Oriented Architectural Elements

To cope with the complexity of large object-oriented software systems, developers organize classe... more To cope with the complexity of large object-oriented software systems, developers organize classes into subsystems using the concepts of module or package. Such modular structure helps software systems to evolve when facing new requirements. The organization of classes into packages and/or subsystems represents the software modularization. the software modularization usually follows interrelationships between classes. Ideally, packages should to be loosely coupled and cohesive to a certain extent. However, Studies show that as software evolves to meet requirements and environment changes, the software modularization gradually drifts and looses quality. As a consequence, the software modularization must be maintained. It is thus important to understand, to assess and to optimize the organization of packages and their relationships. Our claim is that the maintenance of large and complex software modularizations needs approaches that help in: (1) understanding package shapes and relationships; (2) assessing the quality of a modularization, as well as the quality of a single package within a given modularization; (3) optimizing the quality of an existing modulariza- tion. In this thesis, we concentrate on three research fields: software visualizations, metrics and algorithms. At first, we define two visualizations that help maintainers: (1) to understand packages structure, usage and relationships; (2) to spot patterns; and (3) to identify misplaced classes and structural anomalies. In addition to visual- izations, we define a suite of metrics that help in assessing the package design quality (i.e., package cohesion and coupling). We also define metrics that assess the quality of a collection of inter-dependent packages from different view points, such as the degree of package coupling and cycles. Finally, we define a search-based algorithm that automatically reduces package coupling and cycles only by moving classes over existing packages. Our optimization approach takes explicitly into account the origi- nal class organization and package structure. It also allows maintainers to control the optimization process by specifying: (1) the maximal number of classes that may change their packages; (2) the classes that are candidate for moving and the classes that should not; (3) the packages that are candidate for restructuring and the packages that should not; and (4) the maximal number of classes that a given package can entail. The approaches presented in this thesis have been applied to real large object- oriented software systems. The results we obtained demonstrate the usefulness of our visualizations and metrics; and the effectiveness of our optimization algorithm.

Research paper thumbnail of Learning Dependency-based Change Impact Predictors using Independent Change Histories

Information and Software Technology, 2015

Research paper thumbnail of Mining Multi-level API Usage Patterns

2015 IEEE 22nd International Conference on Software Analysis, Evolution, and Reengineering (SANER), 2015

Software developers need to cope with complexity of Application Programming Interfaces (APIs) of ... more Software developers need to cope with complexity of Application Programming Interfaces (APIs) of external libraries or frameworks. However, typical APIs provide several thousands of methods to their client programs, and such large APIs are difficult to learn and use. An API method is generally used within client programs along with other methods of the API of interest. Despite this, co-usage relationships between API methods are often not documented. We propose a technique for mining Multi-Level API Usage Patterns (MLUP) to exhibit the co-usage relationships between methods of the API of interest across interfering usage scenarios. We detect multi-level usage patterns as distinct groups of API methods, where each group is uniformly used across variable client programs, independently of usage contexts. We evaluated our technique through the usage of four APIs having up to 22 client programs per API. For all the studied APIs, our technique was able to detect usage patterns that are, almost all, highly consistent and highly cohesive across a considerable variability of client programs.

Research paper thumbnail of Type Variability and Completeness of Interfaces in Java Applications

ABSTRACT Interfaces are widely used as central design elements of Java applications. Although int... more ABSTRACT Interfaces are widely used as central design elements of Java applications. Although interfaces are abstract types similar to abstract classes, the usage of interfaces in Java applications may considerably differ from the usage of abstract classes. Unlike abstract classes, interfaces are meant to enable multiple inheritance in Java programs. Hence, interfaces are meant to encode shared similarities between classes belonging to different class-type hierarchies. Therefore, it is frequent to use interfaces as partial types, where an interface specifies one specific aspect or usage of its implementing classes. In this paper, we investigate interfaces' usage in Java applications from two perspectives. First, we investigate the usage of interfaces as types of classes belonging to different class-type hierarchies (i.e., interface's type variability). Second, we investigate the usage of interfaces as partial types of implementing classes (i.e., interface's type completeness).

Research paper thumbnail of The Package Blueprint: Visually analyzing and quantifying packages dependencies

Science of Computer Programming, 2014

ABSTRACT Large object-oriented applications are structured over many packages. Packages are impor... more ABSTRACT Large object-oriented applications are structured over many packages. Packages are important but complex structural entities that are difficult to understand since they act as containers of classes, which can have many dependencies with other classes spread over multiple packages. However to be able to take decisions (e.g. refactoring and/or assessment decisions), maintainers face the challenges of managing (sorting, grouping) the massive amount of dependencies between classes spread over multiple packages. To help maintainers, there is a need for at the same time understanding, and quantifying, dependencies between classes as well as understanding how packages as containers of such classes depend on each other. In this paper, we present a visualization, named Package Blueprint, that reveals in detail package internal structure, as well as the dependencies between an observed package and its neighbors, at both package and class levels. Package Blueprintaims at assisting maintainers in understanding package structure and dependencies, in particular when they focus on few packages and want to take refactoring decisions and/or to assess the structure of those packages. A package blueprint is a space filling matrix-based visualization, using two placement strategies that are enclosure and adjacency. Package blueprint is structured around the notion of surfaces that group classes and their dependencies by their packages (i.e., enclosure placement); whilst surfaces are placed next to their parent node which is the package under-analysis (i.e., adjacency placement). We present two views: one stressing how an observed package depends upon the rest of the system and another stressing how the system depends upon that package. To evaluate the contribution of package blueprint for understanding packages we performed an exploratory user study comparing package blueprint with an advanced IDE. The results shows that users of package blueprint are faster in analyzing and assessing package structure. The results are proved statically significant and they show that package blueprint considerably improve the experience of standard browser users.

Research paper thumbnail of Software metric for Java and C++ practices (Workpackage 1.1)

Research paper thumbnail of Multi-Objective Optimization in Rule-Based Design Space Exploration

Design space exploration (DSE) aims to find optimal design candidates of a domain with respect to... more Design space exploration (DSE) aims to find optimal design candidates of a domain with respect to different objectives where design candidates are constrained by complex structural and numerical restrictions.
Rule-based DSE aims to find such candidates that are reachable from an initial model by applying a sequence of exploration rules. Solving a rule-based DSE problem is a difficult challenge due to the inherently dynamic nature of the problem.

In the current paper, we propose to integrate multi-objective optimization techniques by using Non-dominated Sorting Genetic Algorithms (NSGA) to drive rule-based design space exploration. For this purpose, finite populations of the most promising design candidates are maintained wrt. different optimization criteria. In our context, individuals of a generation are defined as a sequence of rule applications leading from an initial model to a candidate model. Populations evolve by mutation and crossover operations which manipulate (change, extend or combine) rule execution sequences to yield new individuals.

Our multi-objective optimization approach for rule-based DSE is domain independent and it is automated by tooling built on the Eclipse framework. The main added value is to seamlessly lift multi-objective optimization techniques to the exploration process preserving both domain independence and a high-level of abstraction. Design candidates will still be represented as models and the evolution of these models as rule execution sequences. Constraints are captured by model queries while objectives can be derived both from models or rule applications.

Research paper thumbnail of How We Design Interfaces, and How to Assess It

Interfaces are widely used in Java applications as central design elements for modular programmin... more Interfaces are widely used in Java applications as central design elements for modular programming to increase program reusability and to ease maintainability of software systems. Despite the importance of interfaces and a considerable research effort that has investigated code quality and concrete classes' design, few works have investigated interfaces' design. In this paper, we empirically study interfaces' design and its impact on the design quality of implementing classes (i.e., class cohesion) analyzing twelve Java object-oriented applications. In this study we propose the "Interface-Implementations Model" that we use to adapt class cohesion metrics to assess the cohesion of interfaces based on their implementations. Moreover, we use other metrics that evaluate the conformance of interfaces to the well-known design principles "Program to an Interface, not an implementation" and "Interface Segregation principle". The results show that software developers abide well by the interface design principles cited above, but they neglect the cohesion property. The results also show that such design practices of interfaces lead to a degraded cohesion of implementing classes, where these latter would be characterized by a worse cohesion than other classes.

Research paper thumbnail of Towards Automatically Improving Package Structure While Respecting Original Design Decisions

"Recently, there has been an important progress in applying search-based optimization techniques ... more "Recently, there has been an important progress in applying search-based optimization techniques to the problem of
software remodularization. Yet, a major part of the existing body
of work addresses the problem of modularizing software systems
from scratch, regardless of the existing packages structure. This
paper presents a novel multi-objective optimization approach
for improving existing packages structure. The optimization approach aims at increasing the cohesion and reducing the coupling and cyclic connectivity of packages, by modifying as less as possible the existing packages organization. Moreover, maintainers can specify several constraints to guide the optimization process with regard to extra design factors. To this contribution, we use the Non-Dominated Sorting Genetic Algorithm (NSGA-II).
We evaluate the optimization approach through an experiment
covering four real-world software systems. The results promise
the effectiveness of our optimization approach for improving
existing packages structure by doing very small modifications."

Keywords: Software Modularization, Package Structure Quality, Package Structure Metrics, Remodularization

Research paper thumbnail of Modularization Metrics: Assessing Package Organization in Legacy Large Object-Oriented Software

There exist many large object-oriented software systems consisting of several thousands of classe... more There exist many large object-oriented software systems consisting of several thousands of classes that are organized into several hundreds of packages. In such software systems, classes cannot be considered as units for software modularization. In such context, packages are not simply classes containers, but they also play the role of modules: a package should focus to provide well identified services to the rest of the software system. Therefore, understanding and assessing package organization is primordial for software maintenance tasks. Although there exist a lot of works proposing metrics for the quality of a single class and/or the quality of inter-class relationships, there exist few works dealing with some aspects for the quality of package organization and relationship. We believe that additional investigations are required for assessing package modularity aspects. The goal of this paper is to provide a complementary set of metrics that assess some modularity principles for packages in large legacy object-oriented software: Information-Hiding, Changeability and Reusability principles. Our metrics are defined with respect to object-oriented dependencies that are caused by inheritance and method call. We validate our metrics theoretically through a careful study of the mathematical properties of each metric.

Keywords: Software Modularization, Package Structure Quality, Package Structure Metrics

Research paper thumbnail of Package Reference Fingerprint: a Rich and Compact Visualization to Understand Package Relationships

Object-oriented languages such as Java, Smalltalk, and C++ structure their programs using package... more Object-oriented languages such as Java, Smalltalk, and C++ structure their programs using packages, allowing classes to be organized into named abstractions. Maintainers of large applications need to understand how packages are structured and how they relate to each other, but this task is very complex because packages often have multiple clients and different roles (class container, code ownership...). Cohesion and coupling are still among the most used metrics, because they help identify candidate packages for restructuring; however, they do not help maintainers understand the structure and interrelationships between packages. In this paper, we present the package fingerprint, a 2D visualization of the references made to and from a package. The proposed visualization offers a semantically rich, but compact and zoomable visualization centered on packages. We focus on two views (incoming and outgoing references) that help users understand how the package under analysis is used by the system and how it uses the system. We applied these views on three large case studies: JBoss, Azureus, and ArgoUML.

Research paper thumbnail of Package Fingerprints: A visual summary of package interface usage

Information & Software Technology, 2010

Context: Object-oriented languages such as Java, Smalltalk, and C++ structure their programs usin... more Context: Object-oriented languages such as Java, Smalltalk, and C++ structure their programs using packages. Maintainers of large systems need to understand how packages relate to each other, but this task is complex because packages often have multiple clients and play different roles (class container, code ownership. . . ). Several approaches have been proposed, among which the use of cohesion and coupling metrics. Such metrics help identify candidate packages for restructuring; however, they do not help maintainers actually understand the structure and interrelationships between packages.

Research paper thumbnail of Package Surface Blueprints: Visually Supporting the Understanding of Package Relationships

Large object-oriented applications are structured over large number of packages. Packages are imp... more Large object-oriented applications are structured over large number of packages. Packages are important but complex structural entities that may be difficult to understand since they play different development roles (i.e., class containers, code ownership basic structure, architectural elements...). Maintainers of large applications face the problem of understanding how packages are structured in general and how they relate to each others. In this paper, we present a compact visualization, named Package Surface Blueprint, that qualifies the relationships that a package has with its neighbours. A Package Surface Blueprint represents packages around the notion of package surfaces: groups of relationships according to the packages they refer to. We present two specific views one stressing the references made by a package and another showing the inheritance structure of a package. We applied the visualization on two large case studies: ArgoUML and Squeak.

Research paper thumbnail of Automatic Package Coupling and Cycle Minimization

Object-oriented (OO) software is usually organized into subsystems using the concepts of package ... more Object-oriented (OO) software is usually organized into subsystems using the concepts of package or module. Such modular structure helps applications to evolve when facing new requirements. However, studies show that as software evolves to meet requirements and environment changes, modularization quality degrades. To help maintainers improve the quality of software modularization we have designed and implemented a heuristic search-based approach for automatically optimizing inter-package connectivity (i.e., dependencies). In this paper, we present our approach and its underlying techniques and algorithm. We show through a case study how it enables maintainers to optimize OO package structure of source code. Our optimization approach is based on Simulated Annealing technique.

Research paper thumbnail of Automatic Package Coupling and Cycle Minimization

Object-oriented (OO) software is usually organized into subsystems using the concepts of package ... more Object-oriented (OO) software is usually organized into subsystems using the concepts of package or module. Such modular structure helps applications to evolve when facing new requirements. However, studies show that as software evolves to meet requirements and environment changes, modularization quality degrades. To help maintainers improve the quality of software modularization we have designed and implemented a heuristic search-based approach for automatically optimizing inter-package connectivity (i.e., dependencies). In this paper, we present our approach and its underlying techniques and algorithm. We show through a case study how it enables maintainers to optimize OO package structure of source code. Our optimization approach is based on Simulated Annealing technique.

Research paper thumbnail of CHARACTERIZING AND EVALUATING THE IMPACT OF SOFTWARE INTERFACE CLONES

Interfaces, if well designed, significantly reduce software complexity and ease maintainability. ... more Interfaces, if well designed, significantly reduce software complexity and ease maintainability. However, as software evolves, the organization and the quality of software interfaces gradually deteriorate. As a consequence, this often leads to increased development cost, lower code quality and reduced reusability.

Research paper thumbnail of Package Fingerprints: a visual summary of package interface usage Hani Abdeena , St´ephane Ducassea

Context: Object-oriented languages such as Java, Smalltalk, and C++ structure their programs usin... more Context: Object-oriented languages such as Java, Smalltalk, and C++ structure their programs using packages. Maintainers of large systems need to understand how packages relate to each other, but this task is complex because packages often have multiple clients and play different roles (class container, code ownership. . . ). Several approaches have been proposed, among which the use of cohesion and coupling metrics. Such metrics help identify candidate packages for restructuring; however, they do not help maintainers actually understand the structure and interrelationships between packages.

Research paper thumbnail of Metrics for Assessing The Design of Software Interfaces

Recent studies have largely investigated the detection of class design anomalies. They proposed a... more Recent studies have largely investigated the detection of class design anomalies. They proposed a large set of metrics that help in detecting those anomalies and in predicting the quality of class design. While those studies and the proposed metrics are valuable, they do not address the particularities of software interfaces. Interfaces define the contracts that spell out how software modules and logic units interact with each other. This paper proposes a list of design defects related to interfaces: shared similarity between interfaces, interface clones and redundancy in interface hierarchy. We identify and describe those design defects through real examples, taken from well-known Java applications. Then we define three metrics that help in automatically estimating the interface design quality, regarding the proposed design anomalies, and identify refactoring candidates. We investigate our metrics and show their usefulness through an empirical study conducted on three large Java applications.

Research paper thumbnail of Software Interfaces: On The Impact of Interface Design Anomalies

Interfaces are recognized as an important mechanism to define contracts governing interactions be... more Interfaces are recognized as an important mechanism to define contracts governing interactions between semiindependent software modules. Well-designed interfaces significantly reduce software complexity and ease maintainability by fostering modularization, hiding implementation details and minimizing the impact caused by changes in the software implementation. However, designing good interfaces is not a trivial task. The presence of interface design defects often yield increased development cost, lower code quality and reduced development productivity. Despite their importance, currently there are only a few research efforts that investigate the quality of interface design. In this paper, we identify and characterize common interface design anomalies and illustrate them via examples taken from well-known open source applications. In order to quantify the presence of interface design anomalies and estimate their impact on the interface design quality, as well on the software quality attributes, such as maintainability, we conduct an empirical study covering 9 open source projects. Building on our empirical results, we develop a set of recommendations to improve interface design.

Research paper thumbnail of Visualizing, Assessing and Re-Modularizing Object-Oriented Architectural Elements

To cope with the complexity of large object-oriented software systems, developers organize classe... more To cope with the complexity of large object-oriented software systems, developers organize classes into subsystems using the concepts of module or package. Such modular structure helps software systems to evolve when facing new requirements. The organization of classes into packages and/or subsystems represents the software modularization. the software modularization usually follows interrelationships between classes. Ideally, packages should to be loosely coupled and cohesive to a certain extent. However, Studies show that as software evolves to meet requirements and environment changes, the software modularization gradually drifts and looses quality. As a consequence, the software modularization must be maintained. It is thus important to understand, to assess and to optimize the organization of packages and their relationships. Our claim is that the maintenance of large and complex software modularizations needs approaches that help in: (1) understanding package shapes and relationships; (2) assessing the quality of a modularization, as well as the quality of a single package within a given modularization; (3) optimizing the quality of an existing modulariza- tion. In this thesis, we concentrate on three research fields: software visualizations, metrics and algorithms. At first, we define two visualizations that help maintainers: (1) to understand packages structure, usage and relationships; (2) to spot patterns; and (3) to identify misplaced classes and structural anomalies. In addition to visual- izations, we define a suite of metrics that help in assessing the package design quality (i.e., package cohesion and coupling). We also define metrics that assess the quality of a collection of inter-dependent packages from different view points, such as the degree of package coupling and cycles. Finally, we define a search-based algorithm that automatically reduces package coupling and cycles only by moving classes over existing packages. Our optimization approach takes explicitly into account the origi- nal class organization and package structure. It also allows maintainers to control the optimization process by specifying: (1) the maximal number of classes that may change their packages; (2) the classes that are candidate for moving and the classes that should not; (3) the packages that are candidate for restructuring and the packages that should not; and (4) the maximal number of classes that a given package can entail. The approaches presented in this thesis have been applied to real large object- oriented software systems. The results we obtained demonstrate the usefulness of our visualizations and metrics; and the effectiveness of our optimization algorithm.