Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Avoid cloning of singleton object

Posted on 2013-10-24
2
274 Views
Last Modified: 2013-10-28
Hi,

Let me know  how to avoid the cloning of the singleton object.

Thanks
0
Comment
Question by:roy_sanu
  • 2
2 Comments
 
LVL 86

Accepted Solution

by:
CEHJ earned 135 total points
ID: 39597705
Make it final. Then the fact that is does NOT implement Cloneable will render it impossible to clone()
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 39604960
:)
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.

791 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question