DefaultClassInstantiator (EasyMock 3.1 API)
Date: 2011-11-10

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.easymock.internal
Class DefaultClassInstantiator

    java.lang.Object
      org.easymock.internal.DefaultClassInstantiator

All Implemented Interfaces:
  IClassInstantiator

    public class DefaultClassInstantiator

extends Object
implements IClassInstantiator

Default class instantiator that is pretty limited. It just hope that the mocked class has a public empty constructor.

Author:
  Henri Tremblay

Constructor Summary
`DefaultClassInstantiator()`

Method Summary
`Object` | `newInstance(Class<?> c)` Try to instantiate a class without using a special constructor.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DefaultClassInstantiator

    public DefaultClassInstantiator()

Method Detail

### newInstance

    public Object newInstance(Class<?> c)
                       throws InstantiationException

  Try to instantiate a class without using a special constructor. See documentation for the algorithm.

  Specified by:
    `newInstance` in interface `IClassInstantiator`
  Parameters:
    `c` - Class to instantiate
  Returns:
    new instance of clazz
  Throws:
    `InstantiationException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001-2011 OFFIS, Tammo Freese, Henri Tremblay. All Rights Reserved.