SlideShare a Scribd company logo
1 of 33
Download to read offline
Yann-Gaël Guéhéneuc
This presentation has been given at OOPSLA, the 27th of October 2004, in Vancouver, BC, Canada.
Software Engineering Laboratory
Department of Computing Science and Operations Research
University of Montreal
Département d’informatique
École des Mines de Nantes
© Yann-Gaël Guéhéneuc and Hervé Albin-Amiot
Recovering Binary Class Relationships:
Putting Icing on the UML Cake
Hervé Albin-Amiot
2/32
Statements
n Maintenance
– 50% of the total cost of a program
n Program understanding
– 50% of the maintainers’ time
n Any help in understanding a program
would reduce its cost!
3/32
Context
n OO maintenance
– Source code
• Most accurate source of information
– Design models
• Useful to understand source code
(architecture of a program)
• Non-existent or obsolete
n Class diagrams help in understanding
source code
4/32
Approach
n Automated recovery of class diagrams
from program source code
– Extract relevant information
– Operational semantics for relevant
constituents of class diagram
– Consistent mapping
• Concepts in programming languages
• Concepts in modeling languages
5/32
Problem
n Use of our approach on Java and UML
– UML class diagrams
• Only a notation! As emphasised during the
panel on “Model Driven Architecture”
– Mapping
• Semantic continuity for some concepts, such as
classes, fields, methods
• Discontinuity for binary class relationships
6/32
Is recovered as
Should be recovered as
Problem (cont’d)
Java
6/32
Is recovered as
Should be recovered as
Problem (cont’d)
Java
7/32
Proposal
n Study of the reverse-engineering of
binary class relationships
– “Consensual” definitions
• At design-level
• At implementation-level
– Properties
– Formalisations
– Recovery algorithms
8/32
Proposal (cont’d)
n Study of the reverse-engineering of
binary class relationships
– Mapping between programming and
modeling languages
– Sound foundations
• Understanding
• Round-tripping
• Design patterns identification
• … and much more!
9/32
Overview
n Motivations
n Formalisations
n Recovery
n Validations
n Conclusion
10/32
Definitions
n Up to now, no consensual definitions
n Study of more than 30 definitions
n “Consensual” definitions
Link Relationship
Origin Means Target Origin Name Target
Instance Direct Instance Entity Association Entity
Instance Field Instance Class Aggregation Entity
Instance Field +
Lifetime property
Instance
Isdescribedby
Class Composition Entity
“Entity” denotes either a class or an interface
11/32
Definitions
n Association
– At design-level
• Conceptual link between two classes
• Multiple instances can be involved
– At implementation-level
• Message sends between instances of two
classes, an origin and a target
• Oriented, irreflexive, anti-symmetric at instance
and class level; asymmetric at instance level
12/32
Definitions
n Aggregation
– At design-level
• An aggregation relationship is an association
between two classes: The whole and the part
– At implementation level
• An aggregation relationship exists between
classes A and B when the definition of A, the
whole, contains instances of B, its part
13/32
Definitions
n Composition
– At design-level
• Aggregation where parts are destroyed when
their whole is destroyed
• Parts might be instantiated before the whole
and exchanged
– At implementation level
• Aggregation with constraint on the lifetimes and
on the ownership of the whole and of its part
14/32
Properties
n Four minimal properties
– Exclusivity, an instance of B (b) is in
relation with only one instance of A (a)
– Invocation site, for method invocations
from a to b
– Lifetime, time of destruction of b wrt. a
– Multiplicity, number of b’s for one a
15/32
Properties
n Four minimal properties
– Exclusivity, EX(A, B) ∈
– Invocation site, IS(A, B) ⊆ {field, parameter,
local variable, …}
– Lifetime, LT(A, B) ∈ {+, −}
– Multiplicity, MU(A, B) ⊂ N ∪ {+∞}
16/32
Formalisations
n Rewriting binary class relationships as
conjunctions of their properties
n Association
AS(A, B) =
(EX(A, B) ∈ B) ∧ (EX(B, A) ∈ B) ∧
(IS(A, B) ⊆ {field…}) ∧ (IS(B, A) = ∅) ∧
(LT(A, B) ∈ {+, −}) ∧ (LT(B, A) ∈ {+, −}) ∧
(MU(A, B) = [0, +∞]) ∧ (MU(B, A) = [0, +∞])
17/32
Formalisations
n Aggregation
AG(A, B) =
(EX(A, B) ∈ B) ∧
(EX(B, A) ∈ B) ∧
(IS(A, B) ⊆ {field, array field, collection field}) ∧
(IS(B, A) = ∅) ∧
(LT(A, B) ∈ {+, −}) ∧
(LT(B, A) ∈ {+, −}) ∧
(MU(A, B) = [0, +∞]) ∧
(MU(B, A) = [1, +∞])
18/32
Formalisations
n Composition
CO(A, B) =
(EX(A, B) = true) ∧
(EX(B, A) = false) ∧
(IS(A, B) ⊆ {field, array field, collection field}) ∧
(IS(B, A) = ∅) ∧
(LT(A, B) = +) ∧
(LT(B, A) = −) ∧
(MU(A, B) = [1, +∞]) ∧
(MU(B, A) = [1, 1])
19/32
Formalisations
n Emergent characteristics
– Minimality of the set of properties
• See p. 307 of the proceedings
– Order among binary class relationships
• Association
• Aggregation
• Composition
– Static and dynamic parts
• IS(A, B), MU(A, B)
• EX(A, B), LT(A, B)
20/32
Overview
n Motivations
n Formalisations
n Recovery
n Validations
n Conclusion
21/32
Recovery
n Binary class relationships
– Not syntactical constructs in source code
– Expressed with four minimal properties
n Recovery
– Computation of the properties
– Inference of existing relationships
22/32
Recovery
n Algorithms
– Static analyses
• IS(A, B), MU(A, B)
– Dynamic analyses
• EX(A, B), LT(A, B)
23/32
Recovery
n Algorithms
– Order among the relationships
– Association
• IS(A, B) with respect to other classes
– Aggregation
• MU(A, B) with respect to associated classes
– Composition
• EX(A, B)
• LT(A, B)
with respect to aggregated classes
24/32
Overview
n Motivations
n Formalisations
n Recovery
n Validations
n Conclusion
25/32
Implementations
n Meta-model
– PDL / PADL
n Static analyses
– PatternsBox / Ptidej
n Dynamic analyses
– Caffeine
Java
Model
Model +
Associations,
aggregations
Model +
Associations,
aggregations,
and composition
Caffeine
PatternsBox / Ptidej
Dedicated parser
PDL / PADL
PDL / PADL
PDL / PADL
Bytecodes
26/32
Experimentations
n Case studies
– Java AWT v1.2.2
• 367 classes
– JHotDraw v5.1
• 171 classes
– JUnit v3.7
• 45 classes
27/32
Experimentations
n Association
– 4,925 for 583 classes but required for aggregation
n Aggregation
n Composition
– Precision and recall of 100% (JUnit only)
Frameworks Found Manual False Hits
Java AWT 17 20 1
JHotDraw 6 8 0
JUnit 1 4 0
Total 24 32 1
Recall: 0.75 Precision: 0.96
28/32
Experimentations
n Emergent characteristics
– Quantitative
• Possible metrics
– Qualitative
• Assessment
• Comparison
– Practicality
29/32
Overview
n Motivations
n Formalisations
n Recovery
n Validations
n Conclusion
30/32
Conclusion
n Any help in understanding a program
would reduce its cost
n Automated recovery of class diagrams
from program source code
n Mapping for binary class relationships
– “Consensual” definitions
– Formalisations
– Recovery algorithms
31/32
Related work
n Civello at OOPSLA 1993
– Classification of binary class relationships
– No operational semantics
n Henderson-Sellers and Barbier in L’Objet 1999
– Properties
– Design-level
n Jackson and Waingold at ISCE 1999
– Operational semantics
– Flavours of association, aggregation only
32/32
Future work
n Detection of other UML constituents
n Static analyses vs. dynamic analyses
n Experimental validations
– Maintainers
– Class diagrams with/without binary
class relationships

More Related Content

What's hot

From RNN to neural networks for cyclic undirected graphs
From RNN to neural networks for cyclic undirected graphsFrom RNN to neural networks for cyclic undirected graphs
From RNN to neural networks for cyclic undirected graphstuxette
 
Cheatsheet unsupervised-learning
Cheatsheet unsupervised-learningCheatsheet unsupervised-learning
Cheatsheet unsupervised-learningSteve Nouri
 
Sat math overview from college board
Sat math overview from college boardSat math overview from college board
Sat math overview from college boardYoAmoNYC
 
1 math t overview
1  math t  overview1  math t  overview
1 math t overviewhadi minhat
 
ECCV2010: distance function and metric learning part 2
ECCV2010: distance function and metric learning part 2ECCV2010: distance function and metric learning part 2
ECCV2010: distance function and metric learning part 2zukun
 
An Importance Sampling Approach to Integrate Expert Knowledge When Learning B...
An Importance Sampling Approach to Integrate Expert Knowledge When Learning B...An Importance Sampling Approach to Integrate Expert Knowledge When Learning B...
An Importance Sampling Approach to Integrate Expert Knowledge When Learning B...NTNU
 
Numerical approach of riemann-liouville fractional derivative operator
Numerical approach of riemann-liouville fractional derivative operatorNumerical approach of riemann-liouville fractional derivative operator
Numerical approach of riemann-liouville fractional derivative operatorIJECEIAES
 
A short and naive introduction to using network in prediction models
A short and naive introduction to using network in prediction modelsA short and naive introduction to using network in prediction models
A short and naive introduction to using network in prediction modelstuxette
 
Math 1300: Section 4-6 Matrix Equations and Systems of Linear Equations
Math 1300: Section 4-6 Matrix Equations and Systems of Linear EquationsMath 1300: Section 4-6 Matrix Equations and Systems of Linear Equations
Math 1300: Section 4-6 Matrix Equations and Systems of Linear EquationsJason Aubrey
 
Neuro -fuzzy-networks-for-identification-of-mathematical-model-parameters-of-...
Neuro -fuzzy-networks-for-identification-of-mathematical-model-parameters-of-...Neuro -fuzzy-networks-for-identification-of-mathematical-model-parameters-of-...
Neuro -fuzzy-networks-for-identification-of-mathematical-model-parameters-of-...Cemal Ardil
 
About functional SIR
About functional SIRAbout functional SIR
About functional SIRtuxette
 
Math 1300: Section 4-2 Systems of Linear Equations; Augmented Matrices
Math 1300: Section 4-2 Systems of Linear Equations; Augmented MatricesMath 1300: Section 4-2 Systems of Linear Equations; Augmented Matrices
Math 1300: Section 4-2 Systems of Linear Equations; Augmented MatricesJason Aubrey
 
Cs6402 design and analysis of algorithms may june 2016 answer key
Cs6402 design and analysis of algorithms may june 2016 answer keyCs6402 design and analysis of algorithms may june 2016 answer key
Cs6402 design and analysis of algorithms may june 2016 answer keyappasami
 
theory of computation lecture 01
theory of computation lecture 01theory of computation lecture 01
theory of computation lecture 018threspecter
 
Subspace Indexing on Grassmannian Manifold for Large Scale Visual Identification
Subspace Indexing on Grassmannian Manifold for Large Scale Visual IdentificationSubspace Indexing on Grassmannian Manifold for Large Scale Visual Identification
Subspace Indexing on Grassmannian Manifold for Large Scale Visual IdentificationUnited States Air Force Academy
 

What's hot (19)

From RNN to neural networks for cyclic undirected graphs
From RNN to neural networks for cyclic undirected graphsFrom RNN to neural networks for cyclic undirected graphs
From RNN to neural networks for cyclic undirected graphs
 
Analytic geometry
Analytic geometryAnalytic geometry
Analytic geometry
 
Cheatsheet unsupervised-learning
Cheatsheet unsupervised-learningCheatsheet unsupervised-learning
Cheatsheet unsupervised-learning
 
Sat math overview from college board
Sat math overview from college boardSat math overview from college board
Sat math overview from college board
 
1 math t overview
1  math t  overview1  math t  overview
1 math t overview
 
ECCV2010: distance function and metric learning part 2
ECCV2010: distance function and metric learning part 2ECCV2010: distance function and metric learning part 2
ECCV2010: distance function and metric learning part 2
 
An Importance Sampling Approach to Integrate Expert Knowledge When Learning B...
An Importance Sampling Approach to Integrate Expert Knowledge When Learning B...An Importance Sampling Approach to Integrate Expert Knowledge When Learning B...
An Importance Sampling Approach to Integrate Expert Knowledge When Learning B...
 
Numerical approach of riemann-liouville fractional derivative operator
Numerical approach of riemann-liouville fractional derivative operatorNumerical approach of riemann-liouville fractional derivative operator
Numerical approach of riemann-liouville fractional derivative operator
 
A short and naive introduction to using network in prediction models
A short and naive introduction to using network in prediction modelsA short and naive introduction to using network in prediction models
A short and naive introduction to using network in prediction models
 
Math 1300: Section 4-6 Matrix Equations and Systems of Linear Equations
Math 1300: Section 4-6 Matrix Equations and Systems of Linear EquationsMath 1300: Section 4-6 Matrix Equations and Systems of Linear Equations
Math 1300: Section 4-6 Matrix Equations and Systems of Linear Equations
 
Neuro -fuzzy-networks-for-identification-of-mathematical-model-parameters-of-...
Neuro -fuzzy-networks-for-identification-of-mathematical-model-parameters-of-...Neuro -fuzzy-networks-for-identification-of-mathematical-model-parameters-of-...
Neuro -fuzzy-networks-for-identification-of-mathematical-model-parameters-of-...
 
About functional SIR
About functional SIRAbout functional SIR
About functional SIR
 
Unit 2
Unit 2Unit 2
Unit 2
 
[ppt]
[ppt][ppt]
[ppt]
 
Math 1300: Section 4-2 Systems of Linear Equations; Augmented Matrices
Math 1300: Section 4-2 Systems of Linear Equations; Augmented MatricesMath 1300: Section 4-2 Systems of Linear Equations; Augmented Matrices
Math 1300: Section 4-2 Systems of Linear Equations; Augmented Matrices
 
Cs6402 design and analysis of algorithms may june 2016 answer key
Cs6402 design and analysis of algorithms may june 2016 answer keyCs6402 design and analysis of algorithms may june 2016 answer key
Cs6402 design and analysis of algorithms may june 2016 answer key
 
Divide and conquer
Divide and conquerDivide and conquer
Divide and conquer
 
theory of computation lecture 01
theory of computation lecture 01theory of computation lecture 01
theory of computation lecture 01
 
Subspace Indexing on Grassmannian Manifold for Large Scale Visual Identification
Subspace Indexing on Grassmannian Manifold for Large Scale Visual IdentificationSubspace Indexing on Grassmannian Manifold for Large Scale Visual Identification
Subspace Indexing on Grassmannian Manifold for Large Scale Visual Identification
 

Similar to Oopsla04.ppt

Instance Based Learning in Machine Learning
Instance Based Learning in Machine LearningInstance Based Learning in Machine Learning
Instance Based Learning in Machine LearningPavithra Thippanaik
 
IJCAI01 MSPC.ppt
IJCAI01 MSPC.pptIJCAI01 MSPC.ppt
IJCAI01 MSPC.pptPtidej Team
 
Introduction to Relational Database Management Systems
Introduction to Relational Database Management SystemsIntroduction to Relational Database Management Systems
Introduction to Relational Database Management SystemsAdri Jovin
 
Logics of Context and Modal Type Theories
Logics of Context and Modal Type TheoriesLogics of Context and Modal Type Theories
Logics of Context and Modal Type TheoriesValeria de Paiva
 
Artificial Intelligence
Artificial Intelligence Artificial Intelligence
Artificial Intelligence butest
 
Arev05c icfca05lessonslearned
Arev05c icfca05lessonslearnedArev05c icfca05lessonslearned
Arev05c icfca05lessonslearnedAhmed Mohamed
 
ML basic & clustering
ML basic & clusteringML basic & clustering
ML basic & clusteringmonalisa Das
 
Machine learning in science and industry — day 1
Machine learning in science and industry — day 1Machine learning in science and industry — day 1
Machine learning in science and industry — day 1arogozhnikov
 
Learning Probabilistic Relational Models using Non-Negative Matrix Factorization
Learning Probabilistic Relational Models using Non-Negative Matrix FactorizationLearning Probabilistic Relational Models using Non-Negative Matrix Factorization
Learning Probabilistic Relational Models using Non-Negative Matrix FactorizationAnthony Coutant
 
Collective entity linking with WSRM DocEng'19
Collective entity linking with WSRM DocEng'19Collective entity linking with WSRM DocEng'19
Collective entity linking with WSRM DocEng'19ngamou
 
Dipso K Mi
Dipso K MiDipso K Mi
Dipso K Mimsabou
 
Joint Word and Entity Embeddings for Entity Retrieval from Knowledge Graph
Joint Word and Entity Embeddings for Entity Retrieval from Knowledge GraphJoint Word and Entity Embeddings for Entity Retrieval from Knowledge Graph
Joint Word and Entity Embeddings for Entity Retrieval from Knowledge GraphFedorNikolaev
 

Similar to Oopsla04.ppt (20)

OOPSLA04.ppt
OOPSLA04.pptOOPSLA04.ppt
OOPSLA04.ppt
 
Instance Based Learning in Machine Learning
Instance Based Learning in Machine LearningInstance Based Learning in Machine Learning
Instance Based Learning in Machine Learning
 
Ijcai01 mspc.ppt
Ijcai01 mspc.pptIjcai01 mspc.ppt
Ijcai01 mspc.ppt
 
Gsdi10
Gsdi10Gsdi10
Gsdi10
 
Lect4
Lect4Lect4
Lect4
 
IJCAI01 MSPC.ppt
IJCAI01 MSPC.pptIJCAI01 MSPC.ppt
IJCAI01 MSPC.ppt
 
Introduction to Relational Database Management Systems
Introduction to Relational Database Management SystemsIntroduction to Relational Database Management Systems
Introduction to Relational Database Management Systems
 
Logics of Context and Modal Type Theories
Logics of Context and Modal Type TheoriesLogics of Context and Modal Type Theories
Logics of Context and Modal Type Theories
 
[ppt]
[ppt][ppt]
[ppt]
 
Artificial Intelligence
Artificial Intelligence Artificial Intelligence
Artificial Intelligence
 
Arev05c icfca05lessonslearned
Arev05c icfca05lessonslearnedArev05c icfca05lessonslearned
Arev05c icfca05lessonslearned
 
ML basic & clustering
ML basic & clusteringML basic & clustering
ML basic & clustering
 
nnml.ppt
nnml.pptnnml.ppt
nnml.ppt
 
Machine learning in science and industry — day 1
Machine learning in science and industry — day 1Machine learning in science and industry — day 1
Machine learning in science and industry — day 1
 
Learning Probabilistic Relational Models using Non-Negative Matrix Factorization
Learning Probabilistic Relational Models using Non-Negative Matrix FactorizationLearning Probabilistic Relational Models using Non-Negative Matrix Factorization
Learning Probabilistic Relational Models using Non-Negative Matrix Factorization
 
Collective entity linking with WSRM DocEng'19
Collective entity linking with WSRM DocEng'19Collective entity linking with WSRM DocEng'19
Collective entity linking with WSRM DocEng'19
 
Dipso K Mi
Dipso K MiDipso K Mi
Dipso K Mi
 
Collaborative DL
Collaborative DLCollaborative DL
Collaborative DL
 
Joint Word and Entity Embeddings for Entity Retrieval from Knowledge Graph
Joint Word and Entity Embeddings for Entity Retrieval from Knowledge GraphJoint Word and Entity Embeddings for Entity Retrieval from Knowledge Graph
Joint Word and Entity Embeddings for Entity Retrieval from Knowledge Graph
 
Bringing Math to LOD
Bringing Math to LODBringing Math to LOD
Bringing Math to LOD
 

More from Yann-Gaël Guéhéneuc

Advice for writing a NSERC Discovery grant application v0.5
Advice for writing a NSERC Discovery grant application v0.5Advice for writing a NSERC Discovery grant application v0.5
Advice for writing a NSERC Discovery grant application v0.5Yann-Gaël Guéhéneuc
 
Ptidej Architecture, Design, and Implementation in Action v2.1
Ptidej Architecture, Design, and Implementation in Action v2.1Ptidej Architecture, Design, and Implementation in Action v2.1
Ptidej Architecture, Design, and Implementation in Action v2.1Yann-Gaël Guéhéneuc
 
Evolution and Examples of Java Features, from Java 1.7 to Java 22
Evolution and Examples of Java Features, from Java 1.7 to Java 22Evolution and Examples of Java Features, from Java 1.7 to Java 22
Evolution and Examples of Java Features, from Java 1.7 to Java 22Yann-Gaël Guéhéneuc
 
Consequences and Principles of Software Quality v0.3
Consequences and Principles of Software Quality v0.3Consequences and Principles of Software Quality v0.3
Consequences and Principles of Software Quality v0.3Yann-Gaël Guéhéneuc
 
Some Pitfalls with Python and Their Possible Solutions v0.9
Some Pitfalls with Python and Their Possible Solutions v0.9Some Pitfalls with Python and Their Possible Solutions v0.9
Some Pitfalls with Python and Their Possible Solutions v0.9Yann-Gaël Guéhéneuc
 
An Explanation of the Unicode, the Text Encoding Standard, Its Usages and Imp...
An Explanation of the Unicode, the Text Encoding Standard, Its Usages and Imp...An Explanation of the Unicode, the Text Encoding Standard, Its Usages and Imp...
An Explanation of the Unicode, the Text Encoding Standard, Its Usages and Imp...Yann-Gaël Guéhéneuc
 
An Explanation of the Halting Problem and Its Consequences
An Explanation of the Halting Problem and Its ConsequencesAn Explanation of the Halting Problem and Its Consequences
An Explanation of the Halting Problem and Its ConsequencesYann-Gaël Guéhéneuc
 
Informaticien(ne)s célèbres (v1.0.2, 19/02/20)
Informaticien(ne)s célèbres (v1.0.2, 19/02/20)Informaticien(ne)s célèbres (v1.0.2, 19/02/20)
Informaticien(ne)s célèbres (v1.0.2, 19/02/20)Yann-Gaël Guéhéneuc
 
On Java Generics, History, Use, Caveats v1.1
On Java Generics, History, Use, Caveats v1.1On Java Generics, History, Use, Caveats v1.1
On Java Generics, History, Use, Caveats v1.1Yann-Gaël Guéhéneuc
 
On Reflection in OO Programming Languages v1.6
On Reflection in OO Programming Languages v1.6On Reflection in OO Programming Languages v1.6
On Reflection in OO Programming Languages v1.6Yann-Gaël Guéhéneuc
 

More from Yann-Gaël Guéhéneuc (20)

Advice for writing a NSERC Discovery grant application v0.5
Advice for writing a NSERC Discovery grant application v0.5Advice for writing a NSERC Discovery grant application v0.5
Advice for writing a NSERC Discovery grant application v0.5
 
Ptidej Architecture, Design, and Implementation in Action v2.1
Ptidej Architecture, Design, and Implementation in Action v2.1Ptidej Architecture, Design, and Implementation in Action v2.1
Ptidej Architecture, Design, and Implementation in Action v2.1
 
Evolution and Examples of Java Features, from Java 1.7 to Java 22
Evolution and Examples of Java Features, from Java 1.7 to Java 22Evolution and Examples of Java Features, from Java 1.7 to Java 22
Evolution and Examples of Java Features, from Java 1.7 to Java 22
 
Consequences and Principles of Software Quality v0.3
Consequences and Principles of Software Quality v0.3Consequences and Principles of Software Quality v0.3
Consequences and Principles of Software Quality v0.3
 
Some Pitfalls with Python and Their Possible Solutions v0.9
Some Pitfalls with Python and Their Possible Solutions v0.9Some Pitfalls with Python and Their Possible Solutions v0.9
Some Pitfalls with Python and Their Possible Solutions v0.9
 
An Explanation of the Unicode, the Text Encoding Standard, Its Usages and Imp...
An Explanation of the Unicode, the Text Encoding Standard, Its Usages and Imp...An Explanation of the Unicode, the Text Encoding Standard, Its Usages and Imp...
An Explanation of the Unicode, the Text Encoding Standard, Its Usages and Imp...
 
An Explanation of the Halting Problem and Its Consequences
An Explanation of the Halting Problem and Its ConsequencesAn Explanation of the Halting Problem and Its Consequences
An Explanation of the Halting Problem and Its Consequences
 
Are CPUs VMs Like Any Others? v1.0
Are CPUs VMs Like Any Others? v1.0Are CPUs VMs Like Any Others? v1.0
Are CPUs VMs Like Any Others? v1.0
 
Informaticien(ne)s célèbres (v1.0.2, 19/02/20)
Informaticien(ne)s célèbres (v1.0.2, 19/02/20)Informaticien(ne)s célèbres (v1.0.2, 19/02/20)
Informaticien(ne)s célèbres (v1.0.2, 19/02/20)
 
Well-known Computer Scientists v1.0.2
Well-known Computer Scientists v1.0.2Well-known Computer Scientists v1.0.2
Well-known Computer Scientists v1.0.2
 
On Java Generics, History, Use, Caveats v1.1
On Java Generics, History, Use, Caveats v1.1On Java Generics, History, Use, Caveats v1.1
On Java Generics, History, Use, Caveats v1.1
 
On Reflection in OO Programming Languages v1.6
On Reflection in OO Programming Languages v1.6On Reflection in OO Programming Languages v1.6
On Reflection in OO Programming Languages v1.6
 
ICSOC'21
ICSOC'21ICSOC'21
ICSOC'21
 
Vissoft21.ppt
Vissoft21.pptVissoft21.ppt
Vissoft21.ppt
 
Service computation20.ppt
Service computation20.pptService computation20.ppt
Service computation20.ppt
 
Serp4 iot20.ppt
Serp4 iot20.pptSerp4 iot20.ppt
Serp4 iot20.ppt
 
Msr20.ppt
Msr20.pptMsr20.ppt
Msr20.ppt
 
Iwesep19.ppt
Iwesep19.pptIwesep19.ppt
Iwesep19.ppt
 
Icsoc20.ppt
Icsoc20.pptIcsoc20.ppt
Icsoc20.ppt
 
Icsoc18.ppt
Icsoc18.pptIcsoc18.ppt
Icsoc18.ppt
 

Recently uploaded

Engage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyEngage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyFrank van der Linden
 
What are the features of Vehicle Tracking System?
What are the features of Vehicle Tracking System?What are the features of Vehicle Tracking System?
What are the features of Vehicle Tracking System?Watsoo Telematics
 
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...Christina Lin
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideChristina Lin
 
Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantAxelRicardoTrocheRiq
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationkaushalgiri8080
 
cybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningcybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningVitsRangannavar
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureDinusha Kumarasiri
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataAdobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataBradBedford3
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxTier1 app
 
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 
The Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfThe Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfPower Karaoke
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
XpertSolvers: Your Partner in Building Innovative Software Solutions
XpertSolvers: Your Partner in Building Innovative Software SolutionsXpertSolvers: Your Partner in Building Innovative Software Solutions
XpertSolvers: Your Partner in Building Innovative Software SolutionsMehedi Hasan Shohan
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityNeo4j
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...gurkirankumar98700
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 

Recently uploaded (20)

Engage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyEngage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The Ugly
 
What are the features of Vehicle Tracking System?
What are the features of Vehicle Tracking System?What are the features of Vehicle Tracking System?
What are the features of Vehicle Tracking System?
 
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
 
Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service Consultant
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanation
 
cybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningcybersecurity notes for mca students for learning
cybersecurity notes for mca students for learning
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with Azure
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataAdobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
 
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 
The Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfThe Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdf
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
XpertSolvers: Your Partner in Building Innovative Software Solutions
XpertSolvers: Your Partner in Building Innovative Software SolutionsXpertSolvers: Your Partner in Building Innovative Software Solutions
XpertSolvers: Your Partner in Building Innovative Software Solutions
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered Sustainability
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 

Oopsla04.ppt

  • 1. Yann-Gaël Guéhéneuc This presentation has been given at OOPSLA, the 27th of October 2004, in Vancouver, BC, Canada. Software Engineering Laboratory Department of Computing Science and Operations Research University of Montreal Département d’informatique École des Mines de Nantes © Yann-Gaël Guéhéneuc and Hervé Albin-Amiot Recovering Binary Class Relationships: Putting Icing on the UML Cake Hervé Albin-Amiot
  • 2. 2/32 Statements n Maintenance – 50% of the total cost of a program n Program understanding – 50% of the maintainers’ time n Any help in understanding a program would reduce its cost!
  • 3. 3/32 Context n OO maintenance – Source code • Most accurate source of information – Design models • Useful to understand source code (architecture of a program) • Non-existent or obsolete n Class diagrams help in understanding source code
  • 4. 4/32 Approach n Automated recovery of class diagrams from program source code – Extract relevant information – Operational semantics for relevant constituents of class diagram – Consistent mapping • Concepts in programming languages • Concepts in modeling languages
  • 5. 5/32 Problem n Use of our approach on Java and UML – UML class diagrams • Only a notation! As emphasised during the panel on “Model Driven Architecture” – Mapping • Semantic continuity for some concepts, such as classes, fields, methods • Discontinuity for binary class relationships
  • 6. 6/32 Is recovered as Should be recovered as Problem (cont’d) Java
  • 7. 6/32 Is recovered as Should be recovered as Problem (cont’d) Java
  • 8. 7/32 Proposal n Study of the reverse-engineering of binary class relationships – “Consensual” definitions • At design-level • At implementation-level – Properties – Formalisations – Recovery algorithms
  • 9. 8/32 Proposal (cont’d) n Study of the reverse-engineering of binary class relationships – Mapping between programming and modeling languages – Sound foundations • Understanding • Round-tripping • Design patterns identification • … and much more!
  • 10. 9/32 Overview n Motivations n Formalisations n Recovery n Validations n Conclusion
  • 11. 10/32 Definitions n Up to now, no consensual definitions n Study of more than 30 definitions n “Consensual” definitions Link Relationship Origin Means Target Origin Name Target Instance Direct Instance Entity Association Entity Instance Field Instance Class Aggregation Entity Instance Field + Lifetime property Instance Isdescribedby Class Composition Entity “Entity” denotes either a class or an interface
  • 12. 11/32 Definitions n Association – At design-level • Conceptual link between two classes • Multiple instances can be involved – At implementation-level • Message sends between instances of two classes, an origin and a target • Oriented, irreflexive, anti-symmetric at instance and class level; asymmetric at instance level
  • 13. 12/32 Definitions n Aggregation – At design-level • An aggregation relationship is an association between two classes: The whole and the part – At implementation level • An aggregation relationship exists between classes A and B when the definition of A, the whole, contains instances of B, its part
  • 14. 13/32 Definitions n Composition – At design-level • Aggregation where parts are destroyed when their whole is destroyed • Parts might be instantiated before the whole and exchanged – At implementation level • Aggregation with constraint on the lifetimes and on the ownership of the whole and of its part
  • 15. 14/32 Properties n Four minimal properties – Exclusivity, an instance of B (b) is in relation with only one instance of A (a) – Invocation site, for method invocations from a to b – Lifetime, time of destruction of b wrt. a – Multiplicity, number of b’s for one a
  • 16. 15/32 Properties n Four minimal properties – Exclusivity, EX(A, B) ∈ – Invocation site, IS(A, B) ⊆ {field, parameter, local variable, …} – Lifetime, LT(A, B) ∈ {+, −} – Multiplicity, MU(A, B) ⊂ N ∪ {+∞}
  • 17. 16/32 Formalisations n Rewriting binary class relationships as conjunctions of their properties n Association AS(A, B) = (EX(A, B) ∈ B) ∧ (EX(B, A) ∈ B) ∧ (IS(A, B) ⊆ {field…}) ∧ (IS(B, A) = ∅) ∧ (LT(A, B) ∈ {+, −}) ∧ (LT(B, A) ∈ {+, −}) ∧ (MU(A, B) = [0, +∞]) ∧ (MU(B, A) = [0, +∞])
  • 18. 17/32 Formalisations n Aggregation AG(A, B) = (EX(A, B) ∈ B) ∧ (EX(B, A) ∈ B) ∧ (IS(A, B) ⊆ {field, array field, collection field}) ∧ (IS(B, A) = ∅) ∧ (LT(A, B) ∈ {+, −}) ∧ (LT(B, A) ∈ {+, −}) ∧ (MU(A, B) = [0, +∞]) ∧ (MU(B, A) = [1, +∞])
  • 19. 18/32 Formalisations n Composition CO(A, B) = (EX(A, B) = true) ∧ (EX(B, A) = false) ∧ (IS(A, B) ⊆ {field, array field, collection field}) ∧ (IS(B, A) = ∅) ∧ (LT(A, B) = +) ∧ (LT(B, A) = −) ∧ (MU(A, B) = [1, +∞]) ∧ (MU(B, A) = [1, 1])
  • 20. 19/32 Formalisations n Emergent characteristics – Minimality of the set of properties • See p. 307 of the proceedings – Order among binary class relationships • Association • Aggregation • Composition – Static and dynamic parts • IS(A, B), MU(A, B) • EX(A, B), LT(A, B)
  • 21. 20/32 Overview n Motivations n Formalisations n Recovery n Validations n Conclusion
  • 22. 21/32 Recovery n Binary class relationships – Not syntactical constructs in source code – Expressed with four minimal properties n Recovery – Computation of the properties – Inference of existing relationships
  • 23. 22/32 Recovery n Algorithms – Static analyses • IS(A, B), MU(A, B) – Dynamic analyses • EX(A, B), LT(A, B)
  • 24. 23/32 Recovery n Algorithms – Order among the relationships – Association • IS(A, B) with respect to other classes – Aggregation • MU(A, B) with respect to associated classes – Composition • EX(A, B) • LT(A, B) with respect to aggregated classes
  • 25. 24/32 Overview n Motivations n Formalisations n Recovery n Validations n Conclusion
  • 26. 25/32 Implementations n Meta-model – PDL / PADL n Static analyses – PatternsBox / Ptidej n Dynamic analyses – Caffeine Java Model Model + Associations, aggregations Model + Associations, aggregations, and composition Caffeine PatternsBox / Ptidej Dedicated parser PDL / PADL PDL / PADL PDL / PADL Bytecodes
  • 27. 26/32 Experimentations n Case studies – Java AWT v1.2.2 • 367 classes – JHotDraw v5.1 • 171 classes – JUnit v3.7 • 45 classes
  • 28. 27/32 Experimentations n Association – 4,925 for 583 classes but required for aggregation n Aggregation n Composition – Precision and recall of 100% (JUnit only) Frameworks Found Manual False Hits Java AWT 17 20 1 JHotDraw 6 8 0 JUnit 1 4 0 Total 24 32 1 Recall: 0.75 Precision: 0.96
  • 29. 28/32 Experimentations n Emergent characteristics – Quantitative • Possible metrics – Qualitative • Assessment • Comparison – Practicality
  • 30. 29/32 Overview n Motivations n Formalisations n Recovery n Validations n Conclusion
  • 31. 30/32 Conclusion n Any help in understanding a program would reduce its cost n Automated recovery of class diagrams from program source code n Mapping for binary class relationships – “Consensual” definitions – Formalisations – Recovery algorithms
  • 32. 31/32 Related work n Civello at OOPSLA 1993 – Classification of binary class relationships – No operational semantics n Henderson-Sellers and Barbier in L’Objet 1999 – Properties – Design-level n Jackson and Waingold at ISCE 1999 – Operational semantics – Flavours of association, aggregation only
  • 33. 32/32 Future work n Detection of other UML constituents n Static analyses vs. dynamic analyses n Experimental validations – Maintainers – Class diagrams with/without binary class relationships