Package org.jmock.internal
Class InvocationDispatcher
- java.lang.Object
-
- org.jmock.internal.InvocationDispatcher
-
- All Implemented Interfaces:
org.hamcrest.SelfDescribing
,ExpectationCollector
public class InvocationDispatcher extends java.lang.Object implements ExpectationCollector, org.hamcrest.SelfDescribing
-
-
Constructor Summary
Constructors Constructor Description InvocationDispatcher()
InvocationDispatcher(java.util.Collection<Expectation> theExpectations, java.util.Collection<StateMachine> theStateMachines)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(Expectation expectation)
void
describeMismatch(Invocation invocation, org.hamcrest.Description description)
void
describeTo(org.hamcrest.Description description)
java.lang.Object
dispatch(Invocation invocation)
boolean
isSatisfied()
StateMachine
newStateMachine(java.lang.String name)
-
-
-
Constructor Detail
-
InvocationDispatcher
public InvocationDispatcher()
-
InvocationDispatcher
public InvocationDispatcher(java.util.Collection<Expectation> theExpectations, java.util.Collection<StateMachine> theStateMachines)
-
-
Method Detail
-
newStateMachine
public StateMachine newStateMachine(java.lang.String name)
-
add
public void add(Expectation expectation)
- Specified by:
add
in interfaceExpectationCollector
-
describeTo
public void describeTo(org.hamcrest.Description description)
- Specified by:
describeTo
in interfaceorg.hamcrest.SelfDescribing
-
describeMismatch
public void describeMismatch(Invocation invocation, org.hamcrest.Description description)
-
isSatisfied
public boolean isSatisfied()
-
dispatch
public java.lang.Object dispatch(Invocation invocation) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
-