InvokeCountMatcher (jMock API Documentation)
Keywords: org.jmock.core.matcher.InvokeCountMatcher class

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

## org.jmock.core.matcher
Class InvokeCountMatcher

    java.lang.Object
      org.jmock.core.matcher.InvokedRecorder
          org.jmock.core.matcher.InvokeCountMatcher

All Implemented Interfaces:
  InvocationMatcher, SelfDescribing, Verifiable

    public class InvokeCountMatcher

extends InvokedRecorder

Constructor Summary
`InvokeCountMatcher(int expectedCount)`

Method Summary
`StringBuffer` | `describeTo(StringBuffer buffer)` Appends the description of this object to the buffer.
`boolean` | `hasDescription()`
`boolean` | `matches(Invocation invocation)`
`void` | `verify()` Throw an AssertionFailedException if any expectations have not been met.

Methods inherited from class org.jmock.core.matcher.InvokedRecorder
`getInvocationCount, hasBeenInvoked, invoked, verifyHasBeenInvoked, verifyHasBeenInvokedExactly`

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

Constructor Detail

### InvokeCountMatcher

    public InvokeCountMatcher(int expectedCount)

Method Detail

### matches

    public boolean matches(Invocation invocation)

  Specified by:
    `matches` in interface `InvocationMatcher`
  Overrides:
    `matches` in class `InvokedRecorder`

### verify

    public void verify()

  Description copied from interface: `Verifiable`
  Throw an AssertionFailedException if any expectations have not been met. Implementations of this method must be idempotent: jMock can call this method more than once when verifying expectations at the end of a test.

  Specified by:
    `verify` in interface `Verifiable`
  Overrides:
    `verify` in class `InvokedRecorder`

### hasDescription

    public boolean hasDescription()

  Specified by:
    `hasDescription` in interface `InvocationMatcher`
  Overrides:
    `hasDescription` in class `InvokedRecorder`

### describeTo

    public StringBuffer describeTo(StringBuffer buffer)

  Description copied from interface: `SelfDescribing`
  Appends the description of this object to the buffer.

  Specified by:
    `describeTo` in interface `SelfDescribing`
  Overrides:
    `describeTo` in class `InvokedRecorder`
  Parameters:
    `buffer` - The buffer that the description is appended to.
  Returns:
    The buffer passed to the invokedMethod.

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