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
AHttpConnection
which usesHttpClient
and attempts to authenticate preemptively.
-
-
Constructor Summary
Constructors Constructor Description PreemptiveAuthHttpClientConnection(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
-
-
-
Constructor Detail
-
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 Detail
-
setBuffer
public void setBuffer(org.eclipse.jgit.util.TemporaryBuffer buffer)
-
getResponseCode
public int getResponseCode() throws IOException
- Specified by:
getResponseCode
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
- Throws:
IOException
-
getURL
public URL getURL()
- Specified by:
getURL
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getResponseMessage
public String getResponseMessage() throws IOException
- Specified by:
getResponseMessage
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
- Throws:
IOException
-
getHeaderFields
public Map<String,List<String>> getHeaderFields()
- Specified by:
getHeaderFields
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getHeaderFields
public List<String> getHeaderFields(@NonNull String name)
- Specified by:
getHeaderFields
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setRequestProperty
public void setRequestProperty(String name, String value)
- Specified by:
setRequestProperty
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setRequestMethod
public void setRequestMethod(String method)
- Specified by:
setRequestMethod
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setUseCaches
public void setUseCaches(boolean usecaches)
- Specified by:
setUseCaches
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setConnectTimeout
public void setConnectTimeout(int timeout)
- Specified by:
setConnectTimeout
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setReadTimeout
public void setReadTimeout(int readTimeout)
- Specified by:
setReadTimeout
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getContentType
public String getContentType()
- Specified by:
getContentType
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getInputStream
public InputStream getInputStream() throws IOException
- Specified by:
getInputStream
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
- Throws:
IOException
-
getHeaderField
public String getHeaderField(String name)
- Specified by:
getHeaderField
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getContentLength
public int getContentLength()
- Specified by:
getContentLength
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setInstanceFollowRedirects
public void setInstanceFollowRedirects(boolean followRedirects)
- Specified by:
setInstanceFollowRedirects
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setDoOutput
public void setDoOutput(boolean dooutput)
- Specified by:
setDoOutput
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setFixedLengthStreamingMode
public void setFixedLengthStreamingMode(int contentLength)
- Specified by:
setFixedLengthStreamingMode
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getOutputStream
public OutputStream getOutputStream()
- Specified by:
getOutputStream
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
setChunkedStreamingMode
public void setChunkedStreamingMode(int chunklen)
- Specified by:
setChunkedStreamingMode
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
getRequestMethod
public String getRequestMethod()
- Specified by:
getRequestMethod
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
usingProxy
public boolean usingProxy()
- Specified by:
usingProxy
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
connect
public void connect() throws IOException
- Specified by:
connect
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
- Throws:
IOException
-
setHostnameVerifier
public void setHostnameVerifier(HostnameVerifier hostnameverifier)
- Specified by:
setHostnameVerifier
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
-
configure
public void configure(KeyManager[] km, TrustManager[] tm, SecureRandom random) throws KeyManagementException
- Specified by:
configure
in interfaceorg.eclipse.jgit.transport.http.HttpConnection
- Throws:
KeyManagementException
-
-