org.mockito.internal.stubbing
Class Stubber

java.lang.Object
  extended by org.mockito.internal.stubbing.Stubber

public class Stubber
extends java.lang.Object


Constructor Summary
Stubber(MockingProgress mockingProgress)
           
 
Method Summary
 void addConsecutiveReturnValue(java.lang.Object value)
           
 void addConsecutiveThrowable(java.lang.Throwable throwable)
           
 void addReturnValue(java.lang.Object value)
           
 void addThrowable(java.lang.Throwable throwable)
           
 void addThrowableForVoidMethod(java.lang.Throwable throwable)
           
 void addVoidMethodForThrowable(InvocationMatcher voidMethodInvocationMatcher)
           
 boolean hasThrowableForVoidMethod()
           
 java.lang.Object resultFor(Invocation invocation)
           
 void setInvocationForPotentialStubbing(InvocationMatcher invocation)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Stubber

public Stubber(MockingProgress mockingProgress)
Method Detail

setInvocationForPotentialStubbing

public void setInvocationForPotentialStubbing(InvocationMatcher invocation)

addReturnValue

public void addReturnValue(java.lang.Object value)

addThrowable

public void addThrowable(java.lang.Throwable throwable)

addConsecutiveReturnValue

public void addConsecutiveReturnValue(java.lang.Object value)

addConsecutiveThrowable

public void addConsecutiveThrowable(java.lang.Throwable throwable)

resultFor

public java.lang.Object resultFor(Invocation invocation)
                           throws java.lang.Throwable
Throws:
java.lang.Throwable

addThrowableForVoidMethod

public void addThrowableForVoidMethod(java.lang.Throwable throwable)

hasThrowableForVoidMethod

public boolean hasThrowableForVoidMethod()

addVoidMethodForThrowable

public void addVoidMethodForThrowable(InvocationMatcher voidMethodInvocationMatcher)