org.riotfamily.forms.fileupload
Class CountingServletInputStream
java.lang.Object
java.io.InputStream
javax.servlet.ServletInputStream
org.riotfamily.forms.fileupload.CountingServletInputStream
- All Implemented Interfaces:
- Closeable
public class CountingServletInputStream
- extends ServletInputStream
ServletInputStream that counts the number of bytes read. This class is used
to provide progress information for file uploads.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CountingServletInputStream
public CountingServletInputStream()
setSourceStream
public void setSourceStream(ServletInputStream sourceStream)
read
public int read()
throws IOException
- Specified by:
read
in class InputStream
- Throws:
IOException
getBytesRead
public long getBytesRead()