java.lang.Object
org.easymock.internal.ObjenesisClassInstantiator
- All Implemented Interfaces:
IClassInstantiator
Class instantiator using Objenesis to perform the instantiation without calling any constructor.
- Author:
- Henri Tremblay
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionnewInstance(Class<?> clazz) Return a new instance of the specified class.
-
Constructor Details
-
ObjenesisClassInstantiator
public ObjenesisClassInstantiator()
-
-
Method Details
-
newInstance
Description copied from interface:IClassInstantiatorReturn a new instance of the specified class. The recommended way is without calling any constructor. This is usually done by doing likeObjectInputStream.readObject()which is JVM specific.- Specified by:
newInstancein interfaceIClassInstantiator- Parameters:
clazz- class to instantiate- Returns:
- new instance of clazz
-