org.globus.ftp
public class DataSourceStream extends java.lang.Object implements DataSource
Modifier and Type | Field and Description |
---|---|
protected int |
bufferSize |
protected java.io.InputStream |
in |
protected long |
totalRead |
Constructor and Description |
---|
DataSourceStream(java.io.InputStream in) |
DataSourceStream(java.io.InputStream in,
int bufferSize) |
protected java.io.InputStream in
protected int bufferSize
protected long totalRead
public DataSourceStream(java.io.InputStream in)
public DataSourceStream(java.io.InputStream in, int bufferSize)
public Buffer read() throws java.io.IOException
DataSource
read
in interface DataSource
java.io.IOException
- if an I/O error occurs.public void close() throws java.io.IOException
DataSource
close
in interface DataSource
java.io.IOException
- if an I/O error occurs.public long totalSize()
DataSource
totalSize
in interface DataSource