@Deprecated public class SimpleHttpFetcher extends BaseHttpFetcher
Modifier and Type | Class and Description |
---|---|
static class |
SimpleHttpFetcher.IdleConnectionMonitorThread
Deprecated.
|
static class |
SimpleHttpFetcher.MyConnectionKeepAliveStrategy
Deprecated.
|
BaseHttpFetcher.RedirectMode
_acceptLanguage, _maxConnectionsPerHost, _maxRedirects, _maxThreads, _minResponseRate, _redirectMode, _userAgent, DEFAULT_ACCEPT_LANGUAGE, DEFAULT_MAX_CONNECTIONS_PER_HOST, DEFAULT_MAX_REDIRECTS, DEFAULT_MIN_RESPONSE_RATE, DEFAULT_REDIRECT_MODE, NO_MIN_RESPONSE_RATE, NO_REDIRECTS
_defaultMaxContentSize, _maxContentSizes, _validMimeTypes, DEFAULT_MAX_CONTENT_SIZE
Constructor and Description |
---|
SimpleHttpFetcher(int maxThreads,
UserAgent userAgent)
Deprecated.
|
SimpleHttpFetcher(UserAgent userAgent)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
void |
abort()
Deprecated.
Terminate any async request being processed.
|
FetchedResult |
fetch(org.apache.http.client.methods.HttpRequestBase request,
String url,
Payload payload)
Deprecated.
|
FetchedResult |
fetch(String url)
Deprecated.
|
protected void |
finalize()
Deprecated.
|
FetchedResult |
get(String url,
Payload payload)
Deprecated.
Get the content stored in the resource referenced by the 'url' parameter.
|
int |
getConnectionRequestTimeout()
Deprecated.
|
int |
getConnectionTimeout()
Deprecated.
|
org.apache.http.HttpVersion |
getHttpVersion()
Deprecated.
|
int |
getMaxRetryCount()
Deprecated.
|
int |
getSocketTimeout()
Deprecated.
|
void |
setConnectionRequestTimeout(int _connectionRequestTimeoutInMs)
Deprecated.
|
void |
setConnectionTimeout(int connectionTimeoutInMs)
Deprecated.
|
void |
setHttpVersion(org.apache.http.HttpVersion httpVersion)
Deprecated.
|
void |
setMaxRetryCount(int maxRetryCount)
Deprecated.
|
void |
setSocketTimeout(int socketTimeoutInMs)
Deprecated.
|
getAcceptLanguage, getMaxConnectionsPerHost, getMaxRedirects, getMaxThreads, getMinResponseRate, getRedirectMode, getUserAgent, setAcceptLanguage, setMaxConnectionsPerHost, setMaxRedirects, setMinResponseRate, setRedirectMode
addValidMimeType, addValidMimeTypes, get, getDefaultMaxContentSize, getMaxContentSize, getMimeTypeFromContentType, getValidMimeTypes, setDefaultMaxContentSize, setMaxContentSize, setValidMimeTypes
public SimpleHttpFetcher(UserAgent userAgent)
public SimpleHttpFetcher(int maxThreads, UserAgent userAgent)
public org.apache.http.HttpVersion getHttpVersion()
public void setHttpVersion(org.apache.http.HttpVersion httpVersion)
public int getSocketTimeout()
public void setSocketTimeout(int socketTimeoutInMs)
public int getConnectionTimeout()
public void setConnectionTimeout(int connectionTimeoutInMs)
public int getConnectionRequestTimeout()
public void setConnectionRequestTimeout(int _connectionRequestTimeoutInMs)
public int getMaxRetryCount()
public void setMaxRetryCount(int maxRetryCount)
public FetchedResult get(String url, Payload payload) throws BaseFetchException
BaseFetcher
get
in class BaseFetcher
url
- a string url for which to get contentpayload
- a populated Payload
FetchedResult
associated with the URLBaseFetchException
- if an error results from fetching the url.public FetchedResult fetch(String url) throws BaseFetchException
BaseFetchException
public FetchedResult fetch(org.apache.http.client.methods.HttpRequestBase request, String url, Payload payload) throws BaseFetchException
BaseFetchException
public void abort()
BaseFetcher
abort
in class BaseFetcher
Copyright © 2009–2016 Crawler-Commons. All rights reserved.