net.i2p.util
Class PartialEepGet
java.lang.Object
net.i2p.util.EepGet
net.i2p.util.PartialEepGet
public class PartialEepGet
- extends EepGet
Fetch exactly the first 'size' bytes into a stream
Anything less or more will throw an IOException
No retries, no min and max size options, no timeout option
Useful for checking .sud versions
- Since:
- 0.7.12
- Author:
- zzz
Fields inherited from class net.i2p.util.EepGet |
_aborted, _actualURL, _alreadyTransferred, _bytesRemaining, _bytesTransferred, _contentType, _context, _currentAttempt, _decompressException, _encodingChunked, _etag, _extraHeaders, _fetchInactivityTimeout, _headersRead, _isGzippedResponse, _keepFetching, _lastModified, _listeners, _log, _notModified, _numRetries, _out, _outputFile, _outputStream, _proxy, _proxyIn, _proxyOut, _redirectLocation, _redirects, _responseCode, _shouldProxy, _shouldWriteErrorToOutput, _transferFailed, _url, CONNECT_TIMEOUT, INACTIVITY_TIMEOUT, MAX_COMPLETE_FAILS, USER_AGENT |
Methods inherited from class net.i2p.util.EepGet |
addAuthorization, addHeader, addStatusListener, doFetch, fetch, fetch, fetch, getContentType, getETag, getLastModified, getNotModified, getStatusCode, readChunkLength, readHeaders, sendRequest, setWriteErrorToOutput, stopFetching, suggestName |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_fetchSize
long _fetchSize
PartialEepGet
public PartialEepGet(I2PAppContext ctx,
String proxyHost,
int proxyPort,
OutputStream outputStream,
String url,
long size)
- Parameters:
size
- fetch exactly this many bytes
main
public static void main(String[] args)
- PartialEepGet [-p 127.0.0.1:4444] [-l #bytes] url
getRequest
protected String getRequest()
throws IOException
- Overrides:
getRequest
in class EepGet
- Throws:
IOException