Upload
others
View
2
Download
0
Embed Size (px)
Citation preview
Platzhalter für Bild, Bild auf Titelfolie hinter das Logo einsetzen
Christoph Seidl, Sven Schuster, Ina Schaefer
May 16, 2015
Generative Software Product Line Development
using Variability-Aware Design Patterns
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 2
Idea: Use Best-Practices for Software Product Line Design
Design Patterns
Sven Schuster‘s
Presentation
Software Product Lines
Design Patterns
This
Presentation
Software Product Lines
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 3
Overview
Strategy
Template Method
Composite
Observer
...
Java
C++
UML Class Diagrams
...
Preprocessor
FOP
Delta Modeling
...
Feature Models
Mappings
Platzhalter für Bild, Bild auf Titelfolie hinter das Logo einsetzen
Foundations
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 5
Variability-Aware Design Patterns
• Analyzed SPLs for design patterns
• Some design patterns are used to realize variability
• Pattern decomposition on features seems to follow certain rules
Variability-Aware Design Patterns
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 6
Role Modeling
• Design patterns are not a specific design
• Role modeling represents dynamic
collaborations as „blueprint“ for a design
• Roles may be mapped to various
entities (parts of code, models etc.)
• Relations describe collaborations and
restrain possible mapping
Roles may represent patterns
Roles may be mapped to a concrete
design in various languages
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 7
Challenge
• How to develop SPLs with variability-aware design patterns?
1 2 3
Platzhalter für Bild, Bild auf Titelfolie hinter das Logo einsetzen
Specification of Design Patterns
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 9
Catalog of Variability-Aware Design Patterns
• Cataloged variability-aware design patterns
• Name
• Intent
• ...
• Design pattern role model (DPRM)
• Usage within SPLs?
Family role model (FRM)
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 10
Family Role Model (FRM) to capture Variability-Awareness
• Represent demands on configuration options of the feature model (semantics)
• Independent of the concrete structure of the feature model (syntax)
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 11
Making Design Patterns Variability-Aware
Family Role Model (FRM)
• Captures demands on configuration
options of feature model
Mapping FRM to DPRM
• Captures how a design pattern is used
within an SPL
• Variability-aware design pattern
Design Pattern Role Model (DPRM)
• Captures entities of the design pattern
and their relation
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 12
Model-Based Catalog of Variability-Aware Design Patterns
Composite
Strategy
Observer
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 13
Summary: Design Pattern Specification
1 2
Platzhalter für Bild, Bild auf Titelfolie hinter das Logo einsetzen
Application of Design Patterns
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 15
Mapping Family Role Model (FRM) to Concrete Feature Model
?
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 16
Summary: Mapping FRMs to Feature Models
3 1 2
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 17
Mapping DPRM to Realization Artifacts
• Multiple different types of realization artifact
• Java, C++, UML Class Diagrams etc.
• Pattern implemented differently, due to ...
• ... language
• ... variability realization mechanism?
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 18
Generation of Design Pattern Realization Artifacts
• Pattern implemented differently, due to ...
• ... language
• ... variability realization mechanism
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 19
Model-Based Generation
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 20
Composers: Eclipse Extension for Model-Based Generation
Composer 1
Composer 2
Composer 3
Composite
Strategy
Observer
Java UML Class Diagrams
Antenna
DeltaJ
FOP
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 21
Summary: Generation of Design Pattern Realization Artifacts
3 1 2
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 22
Implementation
• Eclipse IDE
• Model-Based with EMF Ecore
• Meta model for Role Models (FRM/DPRM), Design Pattern Catalog, Feature Model
• Generation is Model-Based (but does not have to be)
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 23
Currently Supported Pattern Realizations
Pattern Variability Realization Mechanism Language
Observer Antenna Java
Feature-Oriented Programming Java, UML Class Diagrams
DeltaJ Java
Composite Antenna Java
Feature-Oriented Programming Java, UML Class Diagrams
DeltaJ Java
Strategy Antenna Java
Feature-Oriented Programming Java, UML Class Diagrams
DeltaJ Java
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 24
Conclusion
• Generative Software Product Line Development using Variability-Aware Design Patterns
• Support proactive and reaktive development
Mapping and Validation Mapping and Generation
May 16, 2015 | Christoph Seidl | Generative Pattern-Based SPL Development | Page 25
Questions? Comments? Feedback?