In software engineering, the singleton pattern is a software design pattern that restricts the instantiation of a class to a singular instance. One of the well-known "Gang of Four" design patterns, which describes how to solve recurring problems in object-oriented software,[1] the pattern is useful when exactly one object is needed to coordinate actions across a system.
More specifically, the singleton pattern allows objects to:[2]
The term comes from the mathematical concept of a singleton.
{{cite book}}
: CS1 maint: multiple names: authors list (link)
© MMXXIII Rich X Search. We shall prevail. All rights reserved. Rich X Search