Class HTTPSeekableLineReaderFactory
java.lang.Object
org.archive.util.binsearch.impl.HTTPSeekableLineReaderFactory
- All Implemented Interfaces:
SeekableLineReaderFactory
- Direct Known Subclasses:
ApacheHttp43SLRFactory,HTTPURLConnSLRFactory
public abstract class HTTPSeekableLineReaderFactory
extends Object
implements SeekableLineReaderFactory
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsFields inherited from interface org.archive.util.binsearch.SeekableLineReaderFactory
BINSEARCH_BLOCK_SIZE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract voidclose()get()abstract HTTPSeekableLineReaderabstract intgetHttpFactory(String defaultURL) getHttpFactory(HTTPSeekableLineReaderFactory.HttpLibs type, String defaultURL) abstract intabstract intabstract longabstract intabstract booleanvoidreload()abstract voidsetConnectionTimeoutMS(int connectionTimeoutMS) abstract voidsetMaxHostConnections(int maxHostConnections) abstract voidsetMaxTotalConnections(int maxTotalConnections) abstract voidsetNumRetries(int numRetries) abstract voidsetProxyHostPort(String hostPort) abstract voidsetSocketTimeoutMS(int socketTimeoutMS) abstract voidsetStaleChecking(boolean enabled)
-
Field Details
-
defaultURL
-
-
Constructor Details
-
HTTPSeekableLineReaderFactory
protected HTTPSeekableLineReaderFactory()
-
-
Method Details
-
get
- Throws:
IOException
-
getHttpFactory
-
getHttpFactory
public static HTTPSeekableLineReaderFactory getHttpFactory(HTTPSeekableLineReaderFactory.HttpLibs type) -
getHttpFactory
-
getHttpFactory
public static HTTPSeekableLineReaderFactory getHttpFactory(HTTPSeekableLineReaderFactory.HttpLibs type, String defaultURL) -
get
- Specified by:
getin interfaceSeekableLineReaderFactory- Throws:
IOException
-
close
- Specified by:
closein interfaceSeekableLineReaderFactory- Throws:
IOException
-
setProxyHostPort
- Parameters:
hostPort- to proxy requests through - ex. "localhost:3128"
-
setMaxTotalConnections
public abstract void setMaxTotalConnections(int maxTotalConnections) - Parameters:
maxTotalConnections- the HttpConnectionManagerParams config
-
getMaxTotalConnections
public abstract int getMaxTotalConnections()- Returns:
- the HttpConnectionManagerParams maxTotalConnections config
-
setMaxHostConnections
public abstract void setMaxHostConnections(int maxHostConnections) - Parameters:
maxHostConnections- the HttpConnectionManagerParams config
-
getMaxHostConnections
public abstract int getMaxHostConnections()- Returns:
- the HttpConnectionManagerParams maxHostConnections config
-
getConnectionTimeoutMS
public abstract int getConnectionTimeoutMS()- Returns:
- the connectionTimeoutMS
-
setConnectionTimeoutMS
public abstract void setConnectionTimeoutMS(int connectionTimeoutMS) - Parameters:
connectionTimeoutMS- the connectionTimeoutMS to set
-
getSocketTimeoutMS
public abstract int getSocketTimeoutMS()- Returns:
- the socketTimeoutMS
-
setSocketTimeoutMS
public abstract void setSocketTimeoutMS(int socketTimeoutMS) - Parameters:
socketTimeoutMS- the socketTimeoutMS to set
-
setStaleChecking
public abstract void setStaleChecking(boolean enabled) -
isStaleChecking
public abstract boolean isStaleChecking() -
getModTime
public abstract long getModTime()- Specified by:
getModTimein interfaceSeekableLineReaderFactory
-
reload
public void reload()- Specified by:
reloadin interfaceSeekableLineReaderFactory
-
setNumRetries
public abstract void setNumRetries(int numRetries)
-