[Cs3] Question on Singleton Design Pattern
Mikhail Nesterenko
mikhail at cs.kent.edu
Fri Oct 28 08:35:36 EDT 2016
>
>
> For this pattern, there is only one instance. But why are copy constructor,
> overloaded assignment still implemented in this case? When and how are they
> used in other situations? Are there other possible usage for them? Are
> other public methods necessary to use them?
In Singleton, copy constructor and overloaded assingment is not expected to be used
by the clien. For that, they are either made private or, in C++11
standard deleted.
Thanks,
--
Mikhail
More information about the cs3
mailing list