public class I2PSocketEepGet extends EepGet
EepGet.AUTH_MODE, EepGet.AuthState, EepGet.CLIStatusListener, EepGet.Gunzipper, EepGet.StatusListener
_aborted, _actualURL, _alreadyTransferred, _authState, _bytesRemaining, _bytesTransferred, _contentType, _context, _currentAttempt, _decompressException, _encodingChunked, _etag, _etagOrig, _extraHeaders, _fetchHeaderTimeout, _fetchInactivityTimeout, _headersRead, _isGzippedResponse, _keepFetching, _lastModified, _lastModifiedOrig, _listeners, _log, _notModified, _numRetries, _out, _outputFile, _outputStream, _proxy, _proxyIn, _proxyOut, _redirectLocation, _redirects, _responseCode, _responseText, _shouldProxy, _shouldWriteErrorToOutput, _transferFailed, _url, CONNECT_TIMEOUT, INACTIVITY_TIMEOUT, MAX_COMPLETE_FAILS, USER_AGENT
Constructor and Description |
---|
I2PSocketEepGet(I2PAppContext ctx,
I2PSocketManager mgr,
int numRetries,
long minSize,
long maxSize,
String outputFile,
OutputStream outputStream,
String url) |
I2PSocketEepGet(I2PAppContext ctx,
I2PSocketManager mgr,
int numRetries,
String outputFile,
String url) |
Modifier and Type | Method and Description |
---|---|
boolean |
fetch(long fetchHeaderTimeout,
long totalTimeout,
long inactivityTimeout)
We have to override this to close _socket, since we can't use _proxy in super as the I2PSocket.
|
protected String |
getRequest()
Guess we have to override this since
super doesn't strip the http://host from the GET line
which hoses some servers (opentracker)
HTTP proxy was kind enough to do this for us
|
protected void |
readHeaders()
Overridden to disable inline gunzipping
|
protected void |
sendRequest(SocketTimeout timeout)
Look up the address, get a socket from the I2PSocketManager supplied in the constructor,
and send the request.
|
addAuthorization, addHeader, addStatusListener, doFetch, fetch, fetch, getContentType, getETag, getLastModified, getNotModified, getStatusCode, getStatusText, main, parseAuthArgs, readChunkLength, setWriteErrorToOutput, stopFetching, suggestName
public I2PSocketEepGet(I2PAppContext ctx, I2PSocketManager mgr, int numRetries, String outputFile, String url)
public I2PSocketEepGet(I2PAppContext ctx, I2PSocketManager mgr, int numRetries, long minSize, long maxSize, String outputFile, OutputStream outputStream, String url)
public boolean fetch(long fetchHeaderTimeout, long totalTimeout, long inactivityTimeout)
protected void readHeaders() throws IOException
readHeaders
in class EepGet
IOException
protected void sendRequest(SocketTimeout timeout) throws IOException
sendRequest
in class EepGet
timeout
- ignoredIOException
protected String getRequest() throws IOException
getRequest
in class EepGet
IOException