com.mockobjects.io
Class MockPrintWriter

java.lang.Object
  extended byjava.io.Writer
      extended byjava.io.PrintWriter
          extended bycom.mockobjects.io.MockPrintWriter
All Implemented Interfaces:
Verifiable

public class MockPrintWriter
extends java.io.PrintWriter
implements Verifiable

Author:
steve@m3p.co.uk, Francois Beausoleil (fbos@users.sourceforge.net)

Constructor Summary
MockPrintWriter()
           
 
Method Summary
 void close()
           
 void flush()
           
 void setExpectedCloseCalls(int calls)
           
 void setExpectedFlushCalls(int calls)
           
 void setExpectedSegment(java.lang.String aString)
           
 void verify()
          Throw an AssertionFailedException if any expectations have not been met.
 void write(java.lang.String s)
           
 
Methods inherited from class java.io.PrintWriter
checkError, print, print, print, print, print, print, print, print, print, println, println, println, println, println, println, println, println, println, println, write, write, write, write
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MockPrintWriter

public MockPrintWriter()
Method Detail

setExpectedCloseCalls

public void setExpectedCloseCalls(int calls)

setExpectedSegment

public void setExpectedSegment(java.lang.String aString)

write

public void write(java.lang.String s)

setExpectedFlushCalls

public void setExpectedFlushCalls(int calls)

flush

public void flush()

close

public void close()

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


Copyright © 2002 Mock Objects. All Rights Reserved.