Class SingletonException

All Implemented Interfaces:
Serializable

public class SingletonException extends IllegalInstanceException
Thrown when trying to build a second instance of a singleton class. \nThe instance field must be final and initialized on a static bloc; this exception is thrown by the constructor if the instance is not null. \nIf the instance is built on a lazy way, a boolean field may be used to know if the instance is initialized, and initialize the instance at the first lazy call.
Since:
1.0 (Nov 26, 2010), broldev.core.model 0.0.1-SNAPSHOT dependency
Version:
1.0 (Nov 26, 2010)
Author:
Steph GAUDRY
See Also:
Provided by the broldev.core.model project., Serialized Form
  • Constructor Details

    • SingletonException

      public SingletonException()
      Builds an instance of this exception without specifying the class that is at fault
    • SingletonException

      public SingletonException(Class<?> nonInstanciableClass)
      Builds an instance of the exception with the class that an instance is trying to be created
      Parameters:
      nonInstanciableClass - class than an instance may not be built