SlideShare a Scribd company logo
1 of 16
Download to read offline
Utilization of Method Graphs to Measure
Cohesion in Object Oriented Software
Atakan Aral, Tolga Ovatman
Istanbul Technical Universtiy
Faculty of Computer and Informatics
Outline
• Introduction
• Motivation
• Contribution
• Method Graphs
• Clustering & Similarity Measurement
• Results & Discussion
• Conclusion
• Future Work
Introduction
• Cohesion is the harmony of software
components in performing responsibilities
• Hard to measure quantitatively
• Cohesion of a class is usually measured by
examining common data usage of its methods
Motivation
• Conventional techniques analyze object
code and require compilation
• Hard to detect data usage from source code
– Indirect ways to access a variable
• Prevents evaluating incomplete code
• Our aim is to derive a pure source code based
cohesion measure
Contribution
Source Code
Parsing
•Abstract Syntax
tree based Java
Parser
Graph
Extraction
•Java Universal
Network/Graph
Graph
Clustering
•Weak Component
Clustering
Similarity
Measurement
•Adjusted Rand
Index
Correlation
Analysis
•Pearson
Correlation
• A cohesion measure that
– depends purely on static analysis
– considers only method-to-method relations
– is graph based and software-wide
– is highly correlated to LCOM metric
Method Graphs
• Cooperating Methods (CM) relation
– involves method couples that are called
together from another host method.
Class A{
MA1(){
MA2();
B.MB();
}
MA2(){
B.MB();
MA3();
MA4();
}
MA3(){}
MA4(){}
}
MB
MA1MA2
MA3
MA4
Method Graphs
• Method Call (MC) relation
– involves method couples that call one another.
Class A{
MA1(){
MA2();
B.MB();
}
MA2(){}
MA3(){
MA4();
}
MA4(){
MA1();
}
}
MB
MA1MA2
MA3
MA4
Method Graphs
• Method Layout (ML) relation
– involves method couples that are in the same
class.
Class A{
MA1(){}
MA2(){}
MA3(){}
MA4(){}
}
Class B{
MB1(){}
MB2(){}
}
MA1
MA1MA2
MB1
MA4
MB2
Method Graphs
• Internal Call (IC) relation
– involves method couples that call one another
and are in the same class.
Class A{
MA1(){
MA2();
B.MB();
}
MA2(){}
MA3(){
MA4();
}
MA4(){
MA1();
}
}
MB
MA1MA2
MA3
MA4
Clustering & Similarity
• 4 graphs are clustered using Weak
Component Clustering
• 6 clustering couples are compared using
adjusted Rand index
– CM—MC: Are the methods calling each
other, also called together from another body?
– IC—ML: What is the level of fragmentation
within classes?
Results & Discussion
• 14 most popular open-source Java projects
from GitHub and SourceForge
Results & Discussion
Results & Discussion
• Calling two methods, that call each other,
from the body of another method,
decreases the overall cohesion of software
Conclusion
• We suggest a novel technique that allows
to measure software-wide cohesion.
• It uses static source code analysis.
• Results indicate that its correlation to
LCOM HS is 77%.
Future Work
• to adapt our measure to class level
• to use direction—weight data to improve
accuracy
• to build a mathematical basis for the
relation between our measure and the
LCOM metric
• to study on the other correlated groups
Thank you!

More Related Content

Viewers also liked

Introduction to Social Media Marketing and Social Media Strategy
Introduction to Social Media Marketing and Social Media StrategyIntroduction to Social Media Marketing and Social Media Strategy
Introduction to Social Media Marketing and Social Media StrategyAlbert Qian
 
How to Triple Your Job Offers
How to Triple Your Job OffersHow to Triple Your Job Offers
How to Triple Your Job OffersAlbert Qian
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...AtakanAral
 
Analysis of Algorithms II - PS2
Analysis of Algorithms II - PS2Analysis of Algorithms II - PS2
Analysis of Algorithms II - PS2AtakanAral
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...AtakanAral
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...AtakanAral
 
Analysis of Algorithms II - PS5
Analysis of Algorithms II - PS5Analysis of Algorithms II - PS5
Analysis of Algorithms II - PS5AtakanAral
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...AtakanAral
 
50777360 basic-manual-workshop-repair-manuals-325-and-337
50777360 basic-manual-workshop-repair-manuals-325-and-33750777360 basic-manual-workshop-repair-manuals-325-and-337
50777360 basic-manual-workshop-repair-manuals-325-and-337Walter Mazibuko
 
[1]관계chap 9
[1]관계chap 9[1]관계chap 9
[1]관계chap 9현식 조
 

Viewers also liked (11)

Introduction to Social Media Marketing and Social Media Strategy
Introduction to Social Media Marketing and Social Media StrategyIntroduction to Social Media Marketing and Social Media Strategy
Introduction to Social Media Marketing and Social Media Strategy
 
Propuesta de campaña política
Propuesta de campaña políticaPropuesta de campaña política
Propuesta de campaña política
 
How to Triple Your Job Offers
How to Triple Your Job OffersHow to Triple Your Job Offers
How to Triple Your Job Offers
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
 
Analysis of Algorithms II - PS2
Analysis of Algorithms II - PS2Analysis of Algorithms II - PS2
Analysis of Algorithms II - PS2
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
 
Analysis of Algorithms II - PS5
Analysis of Algorithms II - PS5Analysis of Algorithms II - PS5
Analysis of Algorithms II - PS5
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Progres...
 
50777360 basic-manual-workshop-repair-manuals-325-and-337
50777360 basic-manual-workshop-repair-manuals-325-and-33750777360 basic-manual-workshop-repair-manuals-325-and-337
50777360 basic-manual-workshop-repair-manuals-325-and-337
 
[1]관계chap 9
[1]관계chap 9[1]관계chap 9
[1]관계chap 9
 

More from AtakanAral

Subgraph Matching for Resource Allocation in the Federated Cloud Environment
Subgraph Matching for Resource Allocation in the Federated Cloud EnvironmentSubgraph Matching for Resource Allocation in the Federated Cloud Environment
Subgraph Matching for Resource Allocation in the Federated Cloud EnvironmentAtakanAral
 
Quality of Service Channelling for Latency Sensitive Edge Applications
Quality of Service Channelling for Latency Sensitive Edge ApplicationsQuality of Service Channelling for Latency Sensitive Edge Applications
Quality of Service Channelling for Latency Sensitive Edge ApplicationsAtakanAral
 
Resource Mapping Optimization for Distributed Cloud Services - PhD Thesis Def...
Resource Mapping Optimization for Distributed Cloud Services - PhD Thesis Def...Resource Mapping Optimization for Distributed Cloud Services - PhD Thesis Def...
Resource Mapping Optimization for Distributed Cloud Services - PhD Thesis Def...AtakanAral
 
Software Engineering - RS2
Software Engineering - RS2Software Engineering - RS2
Software Engineering - RS2AtakanAral
 
Software Engineering - RS1
Software Engineering - RS1Software Engineering - RS1
Software Engineering - RS1AtakanAral
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Proposal]
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Proposal]Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Proposal]
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Proposal]AtakanAral
 
Improving Resource Utilization in Cloud using Application Placement Heuristics
Improving Resource Utilization in Cloud using Application Placement HeuristicsImproving Resource Utilization in Cloud using Application Placement Heuristics
Improving Resource Utilization in Cloud using Application Placement HeuristicsAtakanAral
 
Analysis of Algorithms - 3
Analysis of Algorithms - 3Analysis of Algorithms - 3
Analysis of Algorithms - 3AtakanAral
 
Analysis of Algorithms - 2
Analysis of Algorithms - 2Analysis of Algorithms - 2
Analysis of Algorithms - 2AtakanAral
 

More from AtakanAral (9)

Subgraph Matching for Resource Allocation in the Federated Cloud Environment
Subgraph Matching for Resource Allocation in the Federated Cloud EnvironmentSubgraph Matching for Resource Allocation in the Federated Cloud Environment
Subgraph Matching for Resource Allocation in the Federated Cloud Environment
 
Quality of Service Channelling for Latency Sensitive Edge Applications
Quality of Service Channelling for Latency Sensitive Edge ApplicationsQuality of Service Channelling for Latency Sensitive Edge Applications
Quality of Service Channelling for Latency Sensitive Edge Applications
 
Resource Mapping Optimization for Distributed Cloud Services - PhD Thesis Def...
Resource Mapping Optimization for Distributed Cloud Services - PhD Thesis Def...Resource Mapping Optimization for Distributed Cloud Services - PhD Thesis Def...
Resource Mapping Optimization for Distributed Cloud Services - PhD Thesis Def...
 
Software Engineering - RS2
Software Engineering - RS2Software Engineering - RS2
Software Engineering - RS2
 
Software Engineering - RS1
Software Engineering - RS1Software Engineering - RS1
Software Engineering - RS1
 
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Proposal]
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Proposal]Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Proposal]
Modeling and Optimization of Resource Allocation in Cloud [PhD Thesis Proposal]
 
Improving Resource Utilization in Cloud using Application Placement Heuristics
Improving Resource Utilization in Cloud using Application Placement HeuristicsImproving Resource Utilization in Cloud using Application Placement Heuristics
Improving Resource Utilization in Cloud using Application Placement Heuristics
 
Analysis of Algorithms - 3
Analysis of Algorithms - 3Analysis of Algorithms - 3
Analysis of Algorithms - 3
 
Analysis of Algorithms - 2
Analysis of Algorithms - 2Analysis of Algorithms - 2
Analysis of Algorithms - 2
 

Recently uploaded

Artyushina_Guest lecture_YorkU CS May 2024.pptx
Artyushina_Guest lecture_YorkU CS May 2024.pptxArtyushina_Guest lecture_YorkU CS May 2024.pptx
Artyushina_Guest lecture_YorkU CS May 2024.pptxAnnaArtyushina1
 
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAOpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAShane Coughlan
 
A Deep Dive into Secure Product Development Frameworks.pdf
A Deep Dive into Secure Product Development Frameworks.pdfA Deep Dive into Secure Product Development Frameworks.pdf
A Deep Dive into Secure Product Development Frameworks.pdfICS
 
Evolving Data Governance for the Real-time Streaming and AI Era
Evolving Data Governance for the Real-time Streaming and AI EraEvolving Data Governance for the Real-time Streaming and AI Era
Evolving Data Governance for the Real-time Streaming and AI Eraconfluent
 
Your Ultimate Web Studio for Streaming Anywhere | Evmux
Your Ultimate Web Studio for Streaming Anywhere | EvmuxYour Ultimate Web Studio for Streaming Anywhere | Evmux
Your Ultimate Web Studio for Streaming Anywhere | Evmuxevmux96
 
[GRCPP] Introduction to concepts (C++20)
[GRCPP] Introduction to concepts (C++20)[GRCPP] Introduction to concepts (C++20)
[GRCPP] Introduction to concepts (C++20)Dimitrios Platis
 
Lessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdfLessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdfSrushith Repakula
 
From Theory to Practice: Utilizing SpiraPlan's REST API
From Theory to Practice: Utilizing SpiraPlan's REST APIFrom Theory to Practice: Utilizing SpiraPlan's REST API
From Theory to Practice: Utilizing SpiraPlan's REST APIInflectra
 
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdfAzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdfryanfarris8
 
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...Neo4j
 
The mythical technical debt. (Brooke, please, forgive me)
The mythical technical debt. (Brooke, please, forgive me)The mythical technical debt. (Brooke, please, forgive me)
The mythical technical debt. (Brooke, please, forgive me)Roberto Bettazzoni
 
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024SimonedeGijt
 
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...Lisi Hocke
 
GraphSummit Milan - Visione e roadmap del prodotto Neo4j
GraphSummit Milan - Visione e roadmap del prodotto Neo4jGraphSummit Milan - Visione e roadmap del prodotto Neo4j
GraphSummit Milan - Visione e roadmap del prodotto Neo4jNeo4j
 
Abortion Pills For Sale WhatsApp[[+27737758557]] In Birch Acres, Abortion Pil...
Abortion Pills For Sale WhatsApp[[+27737758557]] In Birch Acres, Abortion Pil...Abortion Pills For Sale WhatsApp[[+27737758557]] In Birch Acres, Abortion Pil...
Abortion Pills For Sale WhatsApp[[+27737758557]] In Birch Acres, Abortion Pil...drm1699
 

Recently uploaded (20)

Artyushina_Guest lecture_YorkU CS May 2024.pptx
Artyushina_Guest lecture_YorkU CS May 2024.pptxArtyushina_Guest lecture_YorkU CS May 2024.pptx
Artyushina_Guest lecture_YorkU CS May 2024.pptx
 
Abortion Pill Prices Germiston ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
Abortion Pill Prices Germiston ](+27832195400*)[ 🏥 Women's Abortion Clinic in...Abortion Pill Prices Germiston ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
Abortion Pill Prices Germiston ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
 
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAOpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
 
Abortion Pill Prices Polokwane ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
Abortion Pill Prices Polokwane ](+27832195400*)[ 🏥 Women's Abortion Clinic in...Abortion Pill Prices Polokwane ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
Abortion Pill Prices Polokwane ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
 
A Deep Dive into Secure Product Development Frameworks.pdf
A Deep Dive into Secure Product Development Frameworks.pdfA Deep Dive into Secure Product Development Frameworks.pdf
A Deep Dive into Secure Product Development Frameworks.pdf
 
Evolving Data Governance for the Real-time Streaming and AI Era
Evolving Data Governance for the Real-time Streaming and AI EraEvolving Data Governance for the Real-time Streaming and AI Era
Evolving Data Governance for the Real-time Streaming and AI Era
 
Your Ultimate Web Studio for Streaming Anywhere | Evmux
Your Ultimate Web Studio for Streaming Anywhere | EvmuxYour Ultimate Web Studio for Streaming Anywhere | Evmux
Your Ultimate Web Studio for Streaming Anywhere | Evmux
 
[GRCPP] Introduction to concepts (C++20)
[GRCPP] Introduction to concepts (C++20)[GRCPP] Introduction to concepts (C++20)
[GRCPP] Introduction to concepts (C++20)
 
Lessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdfLessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdf
 
From Theory to Practice: Utilizing SpiraPlan's REST API
From Theory to Practice: Utilizing SpiraPlan's REST APIFrom Theory to Practice: Utilizing SpiraPlan's REST API
From Theory to Practice: Utilizing SpiraPlan's REST API
 
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdfAzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
 
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
 
The mythical technical debt. (Brooke, please, forgive me)
The mythical technical debt. (Brooke, please, forgive me)The mythical technical debt. (Brooke, please, forgive me)
The mythical technical debt. (Brooke, please, forgive me)
 
Abortion Clinic In Pretoria ](+27832195400*)[ 🏥 Safe Abortion Pills in Pretor...
Abortion Clinic In Pretoria ](+27832195400*)[ 🏥 Safe Abortion Pills in Pretor...Abortion Clinic In Pretoria ](+27832195400*)[ 🏥 Safe Abortion Pills in Pretor...
Abortion Clinic In Pretoria ](+27832195400*)[ 🏥 Safe Abortion Pills in Pretor...
 
Abortion Pill Prices Aliwal North ](+27832195400*)[ 🏥 Women's Abortion Clinic...
Abortion Pill Prices Aliwal North ](+27832195400*)[ 🏥 Women's Abortion Clinic...Abortion Pill Prices Aliwal North ](+27832195400*)[ 🏥 Women's Abortion Clinic...
Abortion Pill Prices Aliwal North ](+27832195400*)[ 🏥 Women's Abortion Clinic...
 
Abortion Pill Prices Mthatha (@](+27832195400*)[ 🏥 Women's Abortion Clinic In...
Abortion Pill Prices Mthatha (@](+27832195400*)[ 🏥 Women's Abortion Clinic In...Abortion Pill Prices Mthatha (@](+27832195400*)[ 🏥 Women's Abortion Clinic In...
Abortion Pill Prices Mthatha (@](+27832195400*)[ 🏥 Women's Abortion Clinic In...
 
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024
Wired_2.0_CREATE YOUR ULTIMATE LEARNING ENVIRONMENT_JCON_16052024
 
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
 
GraphSummit Milan - Visione e roadmap del prodotto Neo4j
GraphSummit Milan - Visione e roadmap del prodotto Neo4jGraphSummit Milan - Visione e roadmap del prodotto Neo4j
GraphSummit Milan - Visione e roadmap del prodotto Neo4j
 
Abortion Pills For Sale WhatsApp[[+27737758557]] In Birch Acres, Abortion Pil...
Abortion Pills For Sale WhatsApp[[+27737758557]] In Birch Acres, Abortion Pil...Abortion Pills For Sale WhatsApp[[+27737758557]] In Birch Acres, Abortion Pil...
Abortion Pills For Sale WhatsApp[[+27737758557]] In Birch Acres, Abortion Pil...
 

Utilization of Method Graphs to Measure Cohesion in Object Oriented Software

  • 1. Utilization of Method Graphs to Measure Cohesion in Object Oriented Software Atakan Aral, Tolga Ovatman Istanbul Technical Universtiy Faculty of Computer and Informatics
  • 2. Outline • Introduction • Motivation • Contribution • Method Graphs • Clustering & Similarity Measurement • Results & Discussion • Conclusion • Future Work
  • 3. Introduction • Cohesion is the harmony of software components in performing responsibilities • Hard to measure quantitatively • Cohesion of a class is usually measured by examining common data usage of its methods
  • 4. Motivation • Conventional techniques analyze object code and require compilation • Hard to detect data usage from source code – Indirect ways to access a variable • Prevents evaluating incomplete code • Our aim is to derive a pure source code based cohesion measure
  • 5. Contribution Source Code Parsing •Abstract Syntax tree based Java Parser Graph Extraction •Java Universal Network/Graph Graph Clustering •Weak Component Clustering Similarity Measurement •Adjusted Rand Index Correlation Analysis •Pearson Correlation • A cohesion measure that – depends purely on static analysis – considers only method-to-method relations – is graph based and software-wide – is highly correlated to LCOM metric
  • 6. Method Graphs • Cooperating Methods (CM) relation – involves method couples that are called together from another host method. Class A{ MA1(){ MA2(); B.MB(); } MA2(){ B.MB(); MA3(); MA4(); } MA3(){} MA4(){} } MB MA1MA2 MA3 MA4
  • 7. Method Graphs • Method Call (MC) relation – involves method couples that call one another. Class A{ MA1(){ MA2(); B.MB(); } MA2(){} MA3(){ MA4(); } MA4(){ MA1(); } } MB MA1MA2 MA3 MA4
  • 8. Method Graphs • Method Layout (ML) relation – involves method couples that are in the same class. Class A{ MA1(){} MA2(){} MA3(){} MA4(){} } Class B{ MB1(){} MB2(){} } MA1 MA1MA2 MB1 MA4 MB2
  • 9. Method Graphs • Internal Call (IC) relation – involves method couples that call one another and are in the same class. Class A{ MA1(){ MA2(); B.MB(); } MA2(){} MA3(){ MA4(); } MA4(){ MA1(); } } MB MA1MA2 MA3 MA4
  • 10. Clustering & Similarity • 4 graphs are clustered using Weak Component Clustering • 6 clustering couples are compared using adjusted Rand index – CM—MC: Are the methods calling each other, also called together from another body? – IC—ML: What is the level of fragmentation within classes?
  • 11. Results & Discussion • 14 most popular open-source Java projects from GitHub and SourceForge
  • 13. Results & Discussion • Calling two methods, that call each other, from the body of another method, decreases the overall cohesion of software
  • 14. Conclusion • We suggest a novel technique that allows to measure software-wide cohesion. • It uses static source code analysis. • Results indicate that its correlation to LCOM HS is 77%.
  • 15. Future Work • to adapt our measure to class level • to use direction—weight data to improve accuracy • to build a mathematical basis for the relation between our measure and the LCOM metric • to study on the other correlated groups

Editor's Notes

  1. QualitativelyOrdinal scalesDetailed literaturereview
  2. Reusability, maintainability and understandabilityVery useful during developmentAn indicator of conventional cohesion metrics
  3. When we cluster this graph…
  4. Intersection of last 2 relations
  5. it can be easilyandrapidlyextracted