org.apache.jmeter.util
Class SlowOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
org.apache.jmeter.util.SlowOutputStream
- All Implemented Interfaces:
- java.io.Closeable, java.io.Flushable
public class SlowOutputStream
- extends java.io.FilterOutputStream
OutputStream filter to emulate a slow device, e.g. modem
Fields inherited from class java.io.FilterOutputStream |
out |
Constructor Summary |
SlowOutputStream(java.io.OutputStream out,
int cps)
Create wrapped Output Stream toe emulate the requested CPS. |
Method Summary |
void |
write(byte[] b,
int off,
int len)
|
void |
write(int b)
|
Methods inherited from class java.io.FilterOutputStream |
close, flush, write |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SlowOutputStream
public SlowOutputStream(java.io.OutputStream out,
int cps)
- Create wrapped Output Stream toe emulate the requested CPS.
- Parameters:
out
- OutputStreamcps
- characters per second
write
public void write(byte[] b,
int off,
int len)
throws java.io.IOException
- Overrides:
write
in class java.io.FilterOutputStream
- Throws:
java.io.IOException
write
public void write(int b)
throws java.io.IOException
- Overrides:
write
in class java.io.FilterOutputStream
- Throws:
java.io.IOException
Copyright © 1998-2010 Apache Software Foundation. All Rights Reserved.