com.monkeycoder.monkeynetwork
Class BlindContentDownloader
java.lang.Object
com.monkeycoder.monkeynetwork.ContentDownloader
com.monkeycoder.monkeynetwork.BlindContentDownloader
public class BlindContentDownloader
- extends ContentDownloader
This ContentDownloader blindly accepts incoming data until the server ends
the connection.
This class uses monkeynetwork.ini and requires the following
parameters:
network_buffer_size - Size in bytes of the network stream buffer.
- Author:
- David Stephens
|
Method Summary |
protected boolean |
download(TurboBuffer inBuffer,
java.io.InputStream inStream)
Does the actual downloading of the requested content. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BlindContentDownloader
public BlindContentDownloader(HttpHeaderData inHhd)
- Creates a new BlindContentDownloader.
- Parameters:
inHhd - The header data from this request.
download
protected boolean download(TurboBuffer inBuffer,
java.io.InputStream inStream)
throws java.io.IOException,
MonkeyException
- Does the actual downloading of the requested content. This version
reads data from the network blindly assuming that the server will
eventually terminate the connection.
- Specified by:
download in class ContentDownloader
- Parameters:
inBuffer - The TurboBuffer into which the data will be placed.inStream - The InputStream from which the data will be read.
- Returns:
- Whether or not the content has been downloaded successfully.
- Throws:
java.io.IOException - If thrown by underlying code.
MonkeyException - If thrown by underlying code.