Class PreemptiveAuthHttpClientConnection
java.lang.Object
org.jenkinsci.plugins.gitclient.jgit.PreemptiveAuthHttpClientConnection
- All Implemented Interfaces:
org.eclipse.jgit.transport.http.HttpConnection
public class PreemptiveAuthHttpClientConnection
extends Object
implements org.eclipse.jgit.transport.http.HttpConnection
A
HttpConnection which uses HttpClient and attempts to
authenticate preemptively.-
Field Summary
Fields inherited from interface org.eclipse.jgit.transport.http.HttpConnection
HTTP_11_MOVED_PERM, HTTP_11_MOVED_TEMP, HTTP_FORBIDDEN, HTTP_MOVED_PERM, HTTP_MOVED_TEMP, HTTP_NOT_AUTHORITATIVE, HTTP_NOT_FOUND, HTTP_OK, HTTP_SEE_OTHER, HTTP_UNAUTHORIZED -
Constructor Summary
ConstructorsConstructorDescriptionPreemptiveAuthHttpClientConnection(SmartCredentialsProvider credentialsProvider, String urlStr) PreemptiveAuthHttpClientConnection(SmartCredentialsProvider credentialsProvider, String urlStr, Proxy proxy) PreemptiveAuthHttpClientConnection(SmartCredentialsProvider credentialsProvider, String urlStr, Proxy proxy, org.apache.http.client.HttpClient cl) -
Method Summary
Modifier and TypeMethodDescriptionvoidconfigure(KeyManager[] km, TrustManager[] tm, SecureRandom random) voidconnect()intgetHeaderField(String name) getHeaderFields(String name) intgetURL()voidsetBuffer(org.eclipse.jgit.util.TemporaryBuffer buffer) voidsetChunkedStreamingMode(int chunklen) voidsetConnectTimeout(int timeout) voidsetDoOutput(boolean dooutput) voidsetFixedLengthStreamingMode(int contentLength) voidsetHostnameVerifier(HostnameVerifier hostnameverifier) voidsetInstanceFollowRedirects(boolean followRedirects) voidsetReadTimeout(int readTimeout) voidsetRequestMethod(String method) voidsetRequestProperty(String name, String value) voidsetUseCaches(boolean usecaches) boolean
-
Constructor Details
-
PreemptiveAuthHttpClientConnection
public PreemptiveAuthHttpClientConnection(SmartCredentialsProvider credentialsProvider, String urlStr) -
PreemptiveAuthHttpClientConnection
public PreemptiveAuthHttpClientConnection(SmartCredentialsProvider credentialsProvider, String urlStr, Proxy proxy) -
PreemptiveAuthHttpClientConnection
public PreemptiveAuthHttpClientConnection(SmartCredentialsProvider credentialsProvider, String urlStr, Proxy proxy, org.apache.http.client.HttpClient cl)
-
-
Method Details
-
setBuffer
public void setBuffer(org.eclipse.jgit.util.TemporaryBuffer buffer) -
getResponseCode
- Specified by:
getResponseCodein interfaceorg.eclipse.jgit.transport.http.HttpConnection- Throws:
IOException
-
getURL
- Specified by:
getURLin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getResponseMessage
- Specified by:
getResponseMessagein interfaceorg.eclipse.jgit.transport.http.HttpConnection- Throws:
IOException
-
getHeaderFields
- Specified by:
getHeaderFieldsin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getHeaderFields
- Specified by:
getHeaderFieldsin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setRequestProperty
- Specified by:
setRequestPropertyin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setRequestMethod
- Specified by:
setRequestMethodin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setUseCaches
public void setUseCaches(boolean usecaches) - Specified by:
setUseCachesin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setConnectTimeout
public void setConnectTimeout(int timeout) - Specified by:
setConnectTimeoutin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setReadTimeout
public void setReadTimeout(int readTimeout) - Specified by:
setReadTimeoutin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getContentType
- Specified by:
getContentTypein interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getInputStream
- Specified by:
getInputStreamin interfaceorg.eclipse.jgit.transport.http.HttpConnection- Throws:
IOException
-
getHeaderField
- Specified by:
getHeaderFieldin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getContentLength
public int getContentLength()- Specified by:
getContentLengthin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setInstanceFollowRedirects
public void setInstanceFollowRedirects(boolean followRedirects) - Specified by:
setInstanceFollowRedirectsin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setDoOutput
public void setDoOutput(boolean dooutput) - Specified by:
setDoOutputin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setFixedLengthStreamingMode
public void setFixedLengthStreamingMode(int contentLength) - Specified by:
setFixedLengthStreamingModein interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getOutputStream
- Specified by:
getOutputStreamin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setChunkedStreamingMode
public void setChunkedStreamingMode(int chunklen) - Specified by:
setChunkedStreamingModein interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getRequestMethod
- Specified by:
getRequestMethodin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
usingProxy
public boolean usingProxy()- Specified by:
usingProxyin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
connect
- Specified by:
connectin interfaceorg.eclipse.jgit.transport.http.HttpConnection- Throws:
IOException
-
setHostnameVerifier
- Specified by:
setHostnameVerifierin interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
configure
public void configure(KeyManager[] km, TrustManager[] tm, SecureRandom random) throws KeyManagementException - Specified by:
configurein interfaceorg.eclipse.jgit.transport.http.HttpConnection- Throws:
KeyManagementException
-