com.mockobjects
Class AbstractExpectation

java.lang.Object
  extended bycom.mockobjects.AbstractExpectation
All Implemented Interfaces:
Expectation, Verifiable
Direct Known Subclasses:
AbstractExpectationCollection, ExpectationCounter, ExpectationDoubleValue, ExpectationSegment, ExpectationValue

public abstract class AbstractExpectation
extends java.lang.Object
implements Verifiable, Expectation


Constructor Summary
AbstractExpectation(java.lang.String name)
           
 
Method Summary
abstract  void clearActual()
           
 boolean hasExpectations()
          Return true if any expectations have been set on this object.
 void setFailOnVerify()
          If an incorrect actual value is set, defer reporting this as a failure until verify() is called on this object.
abstract  void verify()
          Throw an AssertionFailedException if any expectations have not been met.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.mockobjects.Expectation
setExpectNothing
 

Constructor Detail

AbstractExpectation

public AbstractExpectation(java.lang.String name)
Method Detail

clearActual

public abstract void clearActual()

hasExpectations

public boolean hasExpectations()
Description copied from interface: Expectation
Return true if any expectations have been set on this object.

Specified by:
hasExpectations in interface Expectation

setFailOnVerify

public void setFailOnVerify()
Description copied from interface: Expectation
If an incorrect actual value is set, defer reporting this as a failure until verify() is called on this object.

Specified by:
setFailOnVerify in interface Expectation

verify

public abstract void verify()
Description copied from interface: Verifiable
Throw an AssertionFailedException if any expectations have not been met.

Specified by:
verify in interface Verifiable


Copyright © 2002 Mock Objects. All Rights Reserved.