Constructor and Description |
---|
SingletonHandler() |
Modifier and Type | Method and Description |
---|---|
static Singleton |
getSingelton(Class<? extends Singleton> singletonClass)
This method helps to retrieve the single instance of a
Singleton singletonClass . |
public static Singleton getSingelton(Class<? extends Singleton> singletonClass) throws SecurityException, NoSuchFieldException, IllegalArgumentException, IllegalAccessException
Singleton
singletonClass
.singletonClass
- the class for which theSecurityException
- forwarded from Class.getField(String)
NoSuchFieldException
- forwarded from Class.getField(String)
IllegalArgumentException
- forwarded from Field.get(Object)
IllegalAccessException
- forwarded from Field.get(Object)