org.jmock.core
Class AbstractDynamicMock
java.lang.Object
org.jmock.core.AbstractDynamicMock
- All Implemented Interfaces:
- DynamicMock, Verifiable
- Direct Known Subclasses:
- CGLIBCoreMock, CoreMock
public abstract class AbstractDynamicMock
- extends Object
- implements DynamicMock
AbstractDynamicMock
public AbstractDynamicMock(Class mockedType,
String name)
AbstractDynamicMock
public AbstractDynamicMock(Class mockedType,
String name,
InvocationDispatcher invocationDispatcher)
getMockedType
public Class getMockedType()
- Specified by:
getMockedType
in interface DynamicMock
mockInvocation
protected Object mockInvocation(Invocation invocation)
throws Throwable
- Throws:
Throwable
verify
public void verify()
- Description copied from interface:
Verifiable
- Throw an AssertionFailedException if any expectations have not been met.
- Specified by:
verify
in interface Verifiable
toString
public String toString()
- Overrides:
toString
in class Object
getMockName
public String getMockName()
setDefaultStub
public void setDefaultStub(Stub newDefaultStub)
- Specified by:
setDefaultStub
in interface DynamicMock
addInvokable
public void addInvokable(Invokable invokable)
- Specified by:
addInvokable
in interface DynamicMock
reset
public void reset()
- Specified by:
reset
in interface DynamicMock
mockNameFromClass
public static String mockNameFromClass(Class c)