net.esper.util
Class GenericFactory<T>
java.lang.Object
net.esper.util.GenericFactory<T>
public class GenericFactory<T>
- extends Object
Factory for an instance of any type. Employs Class.newInstance to instantiate.
Method Summary |
T |
create()
Create instance of class. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GenericFactory
public GenericFactory(Class<T> clazz)
- Ctor.
- Parameters:
clazz
- Class of which instace must be created
create
public T create()
throws IllegalAccessException,
InstantiationException
- Create instance of class.
- Returns:
- instance
- Throws:
IllegalAccessException
- is thrown by Class.newInstance
InstantiationException
- is thrown by Class.newInstance