Hacker News new | ask | show | jobs
by nobullet 4275 days ago
You are right: it would be great to have one good approach. By the way, holder solves the problem when you don't need to pass arguments to singleton instance. In other cases Safe DCL, Safe Local DCL or Synchronized CL will work.