JAVA DESIGN PATTERN Questions and Answers

Explain how can you prevent creating another instance of singleton using clone() method?

The preferred way to prevent creating another instance of a singleton is by not implementing Cloneable interface and if you do just throw an exception from clone() method “ not to create a clone of singleton class”.