Class AccessTokenPolarisHttpClient


  • public class AccessTokenPolarisHttpClient
    extends com.synopsys.integration.rest.client.AuthenticatingIntHttpClient
    • Field Summary

      • Fields inherited from class com.synopsys.integration.rest.client.IntHttpClient

        DEFAULT_TIMEOUT, ERROR_MSG_PROXY_INFO_NULL, logger
    • Constructor Summary

      Constructors 
      Constructor Description
      AccessTokenPolarisHttpClient​(com.synopsys.integration.log.IntLogger logger, int timeout, com.synopsys.integration.rest.proxy.ProxyInfo proxyInfo, com.synopsys.integration.rest.HttpUrl baseUrl, java.lang.String accessToken, com.google.gson.Gson gson, com.synopsys.integration.rest.support.AuthenticationSupport authenticationSupport)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      com.synopsys.integration.rest.response.Response attemptAuthentication()  
      protected void completeAuthenticationRequest​(org.apache.http.client.methods.HttpUriRequest request, com.synopsys.integration.rest.response.Response response)  
      com.synopsys.integration.rest.HttpUrl getPolarisServerUrl()  
      void handleErrorResponse​(org.apache.http.client.methods.HttpUriRequest request, com.synopsys.integration.rest.response.Response response)  
      boolean isAlreadyAuthenticated​(org.apache.http.client.methods.HttpUriRequest request)  
      • Methods inherited from class com.synopsys.integration.rest.client.AuthenticatingIntHttpClient

        attemptConnection, authenticateRequest, canConnect, execute, isUnauthorizedOrForbidden
      • Methods inherited from class com.synopsys.integration.rest.client.IntHttpClient

        addCommonRequestHeader, addCommonRequestHeaders, addToHttpClientBuilder, createHttpUriRequest, createRequestBuilder, createRequestBuilder, execute, executeGetRequestIfModifiedSince, extractErrorResponse, getClientBuilder, getCommonRequestHeaders, getCredentialsProvider, getDefaultRequestConfigBuilder, getLogger, getProxyInfo, getTimeoutInSeconds, isAlwaysTrustServerCertificate, logRequestHeaders, logResponseHeaders, removeCommonRequestHeader, throwExceptionForError
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AccessTokenPolarisHttpClient

        public AccessTokenPolarisHttpClient​(com.synopsys.integration.log.IntLogger logger,
                                            int timeout,
                                            com.synopsys.integration.rest.proxy.ProxyInfo proxyInfo,
                                            com.synopsys.integration.rest.HttpUrl baseUrl,
                                            java.lang.String accessToken,
                                            com.google.gson.Gson gson,
                                            com.synopsys.integration.rest.support.AuthenticationSupport authenticationSupport)
    • Method Detail

      • handleErrorResponse

        public void handleErrorResponse​(org.apache.http.client.methods.HttpUriRequest request,
                                        com.synopsys.integration.rest.response.Response response)
        Overrides:
        handleErrorResponse in class com.synopsys.integration.rest.client.IntHttpClient
      • isAlreadyAuthenticated

        public boolean isAlreadyAuthenticated​(org.apache.http.client.methods.HttpUriRequest request)
        Specified by:
        isAlreadyAuthenticated in class com.synopsys.integration.rest.client.AuthenticatingIntHttpClient
      • completeAuthenticationRequest

        protected void completeAuthenticationRequest​(org.apache.http.client.methods.HttpUriRequest request,
                                                     com.synopsys.integration.rest.response.Response response)
        Specified by:
        completeAuthenticationRequest in class com.synopsys.integration.rest.client.AuthenticatingIntHttpClient
      • attemptAuthentication

        public final com.synopsys.integration.rest.response.Response attemptAuthentication()
                                                                                    throws com.synopsys.integration.exception.IntegrationException
        Specified by:
        attemptAuthentication in class com.synopsys.integration.rest.client.AuthenticatingIntHttpClient
        Throws:
        com.synopsys.integration.exception.IntegrationException
      • getPolarisServerUrl

        public com.synopsys.integration.rest.HttpUrl getPolarisServerUrl()