2015-08-13 23:54:40 +02:00
|
|
|
---
|
|
|
|
layout: pattern
|
|
|
|
title: Multiton
|
|
|
|
folder: multiton
|
2015-08-15 18:03:05 +02:00
|
|
|
permalink: /patterns/multiton/
|
2015-08-20 21:40:07 +02:00
|
|
|
categories: Creational
|
|
|
|
tags: Java
|
2015-08-13 23:54:40 +02:00
|
|
|
---
|
|
|
|
|
|
|
|
**Intent:** Ensure a class only has limited number of instances, and provide a
|
|
|
|
global point of access to them.
|
|
|
|
|
|
|
|

|
|
|
|
|
|
|
|
**Applicability:** Use the Multiton pattern when
|
|
|
|
|
2015-08-15 18:03:05 +02:00
|
|
|
* there must be specific number of instances of a class, and they must be accessible to clients from a well-known access point
|