27 lines
637 B
Markdown
27 lines
637 B
Markdown
---
|
||
layout: pattern
|
||
title: Twin
|
||
folder: twin
|
||
permalink: /patterns/twin/
|
||
categories: Structural
|
||
tags:
|
||
- Extensibility
|
||
---
|
||
|
||
## Intent
|
||
Twin pattern is a design pattern which provides a standard solution to simulate multiple
|
||
inheritance in java
|
||
|
||
## Class diagram
|
||

|
||
|
||
## Applicability
|
||
Use the Twin idiom when
|
||
|
||
* To simulate multiple inheritance in a language that does not support this feature.
|
||
* To avoid certain problems of multiple inheritance such as name clashes.
|
||
|
||
## Credits
|
||
|
||
* [Twin – A Design Pattern for Modeling Multiple Inheritance](http://www.ssw.uni-linz.ac.at/Research/Papers/Moe99/Paper.pdf)
|