Live briefing
Everything about Singleton pattern
Programming technique to restrict a class to a single instance
In object-oriented programming, the singleton pattern is a software design pattern that restricts the instantiation of a class to a singular instance. It is one of the well-known "Gang of Four" design patterns, which describe how to solve recurring problems in object-oriented software. The pattern is useful when exactly one object is needed to coordinate actions across a system. Wikipedia →
🧭 Start here: a 6-step reading path
- Read the overview: Singleton patternA 5-minute orientation
- Skim a recent paper: Singleton mesh patterns in multidimensional permutationsInfluential work since 2022
- Pick up a classic book: Objects first with JavaThe most-reprinted book on the subject
- Read the landmark paper: The Parametric Singleton Design Pattern.Cited 3 times
- Go sideways: Double-checked lockingA closely related topic
- Go sideways: Dependency injectionA closely related topic
📖 Definitions
Noun A creational design pattern that restricts the instantiation of a class to one object.
🗂️ The subject at a glance
🏆 Landmark papers (most cited)
The Parametric Singleton Design Pattern.
Pseudo-singleton pattern and agnostic business layer for multi-engineer, synchronous, heterogeneous CAD
The use of the Singleton pattern in software product development
PENERAPAN SINGLETON PATTERN PADA SISTEM AUTENTIKASI JWT UNTUK MENINGKATKAN PERFORMA APLIKASI
ANALISIS PENERAPAN DESIGN PATTERN SINGLETON DALAM PENGELOLAAN KONEKSI DATABASE UNTUK EFISIENSI MEMORI
Thread Specific Singletons: Handling Singleton Pattern Errors in Multi-Threaded Applications and their Variations.
🆕 Influential since 2022
📚 Books worth reading
Objects first with JavaDavid J. Barnes, Michael Kolling · 2002
Design PatternsErich Gamma, John Vlissides · 1995- 📕Practical foundations for programming languagesHarper, Robert · 2012
Cracking the Chinese PuzzlesT. K. Ann · 1984
Program development in JavaBarbara Liskov, John Guttag · 2000
Learning JavaScript Design PatternAddy Osmani · 2012
97 Things Every Programmer Should KnowKevlin Henney · 2010
Bloody Murder: From the Detective Story to the Crime NovelJulian Symons · 1972
Ranked by number of editions on Open Library, a rough measure of how lasting a book is.
🔗 Related topics
- Double-checked locking In software engineering, double-checked locking (also known as "double-checked locking optimization") is a software design pattern used to reduce the overhead…
- Dependency injection In software engineering, dependency injection is a programming technique in which an object or function receives other objects or functions that it requires…
- Lazy initialization In computer programming, lazy initialization is the tactic of delaying the creation of an object, the calculation of a value, or some other expensive process…
- Wrapper library Wrapper libraries (or library wrappers) consist of a thin layer of code (a "shim") which translates a library's existing interface into a compatible interface…
- Multiton pattern In software engineering, the multiton pattern is a design pattern which generalizes the singleton pattern. Whereas the singleton allows only one instance…
- Object pool pattern The object pool pattern is a software creational design pattern that uses a set of initialized objects kept ready to use – a "pool" – rather than allocating…
- Java syntax The syntax of Java is the set of rules defining how a Java program is written and interpreted. The syntax is mostly derived from C and C++. Unlike C++…
- Active record pattern In software engineering, the active record pattern is an architectural pattern. It is found in software that stores in-memory object data in relational…