com.norconex.collector.http.handler.impl
Class DefaultHttpClientInitializer
java.lang.Object
com.norconex.collector.http.handler.impl.DefaultHttpClientInitializer
- All Implemented Interfaces:
- IHttpClientInitializer, IXMLConfigurable, Serializable
public class DefaultHttpClientInitializer
- extends Object
- implements IHttpClientInitializer, IXMLConfigurable
Default implementation of IHttpClientInitializer
.
XML configuration usage:
<httpClientInitializer class="com.norconex.collector.http.handler.impl.DefaultHttpClientInitializer">
<cookiesDisabled>[false|true]</cookiesDisabled>
<userAgent>...</userAgent>
<authMethod>[form|basic|digest]</authMethod>
<authUsername>...</authUsername>
<authPassword>...</authPassword>
<authUsernameField>...</authUsernameField>
<authPasswordField>...</authPasswordField>
<authURL>...</authURL>
<proxyHost>...</proxyHost>
<proxyPort>...</proxyPort>
<proxyUsername>...</proxyUsername>
<proxyPassword>...</proxyPassword>
<proxyRealm>...</proxyRealm>
</httpClientInitializer>
- Author:
- Pascal Essiembre
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AUTH_METHOD_FORM
public static final String AUTH_METHOD_FORM
- See Also:
- Constant Field Values
AUTH_METHOD_BASIC
public static final String AUTH_METHOD_BASIC
- See Also:
- Constant Field Values
AUTH_METHOD_DIGEST
public static final String AUTH_METHOD_DIGEST
- See Also:
- Constant Field Values
DefaultHttpClientInitializer
public DefaultHttpClientInitializer()
initializeHTTPClient
public void initializeHTTPClient(org.apache.http.impl.client.DefaultHttpClient httpClient)
- Specified by:
initializeHTTPClient
in interface IHttpClientInitializer
loadFromXML
public void loadFromXML(Reader in)
- Specified by:
loadFromXML
in interface IXMLConfigurable
saveToXML
public void saveToXML(Writer out)
throws IOException
- Specified by:
saveToXML
in interface IXMLConfigurable
- Throws:
IOException
getAuthMethod
public String getAuthMethod()
setAuthMethod
public void setAuthMethod(String authMethod)
getAuthUsernameField
public String getAuthUsernameField()
setAuthUsernameField
public void setAuthUsernameField(String authUsernameField)
getAuthUsername
public String getAuthUsername()
setAuthUsername
public void setAuthUsername(String authUsername)
getAuthPasswordField
public String getAuthPasswordField()
setAuthPasswordField
public void setAuthPasswordField(String authPasswordField)
getAuthPassword
public String getAuthPassword()
setAuthPassword
public void setAuthPassword(String authPassword)
isCookiesDisabled
public boolean isCookiesDisabled()
setCookiesDisabled
public void setCookiesDisabled(boolean cookiesDisabled)
getAuthURL
public String getAuthURL()
setAuthURL
public void setAuthURL(String authURL)
getUserAgent
public String getUserAgent()
setUserAgent
public void setUserAgent(String userAgent)
getProxyHost
public String getProxyHost()
setProxyHost
public void setProxyHost(String proxyHost)
getProxyPort
public int getProxyPort()
setProxyPort
public void setProxyPort(int proxyPort)
getProxyUsername
public String getProxyUsername()
setProxyUsername
public void setProxyUsername(String proxyUsername)
getProxyPassword
public String getProxyPassword()
setProxyPassword
public void setProxyPassword(String proxyPassword)
getProxyRealm
public String getProxyRealm()
setProxyRealm
public void setProxyRealm(String proxyRealm)
authenticateUsingForm
protected void authenticateUsingForm(org.apache.http.impl.client.DefaultHttpClient httpClient)
Copyright © 2009-2013 Norconex Inc.. All Rights Reserved.