Class ValidationServiceClientBuilder

java.lang.Object
ch.admin.suis.client.core.service.ValidationServiceClientBuilder

public abstract class ValidationServiceClientBuilder extends Object
A builder for creating an implementation object for the IValidationServiceClient interface.
  • Constructor Details

    • ValidationServiceClientBuilder

      public ValidationServiceClientBuilder()
  • Method Details

    • newBuilder

      public static ValidationServiceClientBuilder newBuilder()
    • build

      public abstract IValidationServiceClient build()
      Build a new validation service client instance using all the configuration previously specified in this builder.
      Returns:
      a new validation service client instance.
    • credential

      public abstract ValidationServiceClientBuilder credential(de.intarsys.aaa.authenticate.impl.UserPasswordCredential credential)
      Sets the credential to use when the service requires basic authentication.
      Parameters:
      credential - the credential to use
      Returns:
      an updated builder instance
    • proxyCredential

      public abstract ValidationServiceClientBuilder proxyCredential(de.intarsys.aaa.authenticate.impl.UserPasswordCredential proxyCredential)
      Sets the credential to use when configured proxy requires basic authentication.
      Parameters:
      proxyCredential - the proxy credential to use
      Returns:
      an updated builder instance
    • proxyHost

      public abstract ValidationServiceClientBuilder proxyHost(String proxyHost)
      Sets the name of a proxy server to use when contacting the validation service.
      Parameters:
      proxyHost - the name of the proxy server
      Returns:
      an updated builder instance
    • proxyPort

      public abstract ValidationServiceClientBuilder proxyPort(int proxyPort)
      Sets the port of a proxy server to use when contacting the validation service.
      Parameters:
      proxyPort - the port at which the proxy server is listening
      Returns:
      an updated builder instance
    • serviceUrl

      public abstract ValidationServiceClientBuilder serviceUrl(String serviceUrl)
      Sets the URL of the validation service. This configuration item is required.
      Parameters:
      serviceUrl - the URL of the validation service
      Returns:
      an updated builder instance
    • sslContext

      public abstract ValidationServiceClientBuilder sslContext(SSLContext sslContext)
      Sets an SSLContext to use when contacting the validation service.
      Parameters:
      sslContext - the SSLContext to use
      Returns:
      an updated builder instance
    • wireLogging

      public abstract ValidationServiceClientBuilder wireLogging(boolean wireLogging)
      Sets a flag specifying whether to dump the request and response payload at INFO log level.
      Parameters:
      wireLogging - the SSLContext to use
      Returns:
      an updated builder instance