Class WebServiceDetails

java.lang.Object
com.nimbusds.common.config.WebServiceDetails
All Implemented Interfaces:
LoggableConfiguration
Direct Known Subclasses:
Json2LdapDetails

public class WebServiceDetails extends Object implements LoggableConfiguration
Web service connect details.

The configuration is stored as public fields which become immutable (final) after their initialisation.

Property keys: [prefix]*

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    final String
    Optional API key to include with requests to the web service, null if none.
    final int
    Specifies an HTTP connect timeout for web service requests, in milliseconds.
    static final int
    The default HTTP connect timeout for web service requests (disabled).
    static final int
    The default HTTP read timeout for web service requests (disabled).
    static final boolean
    The default self-signed certificate policy.
    final int
    Specifies an HTTP read timeout for web service requests, in milliseconds.
    final boolean
    Specifies whether to accept self-signed X.509 certificates presented by the web service (for HTTPS connections).
    final URL
    The HTTP(S) URL of the web service.

    Fields inherited from interface com.nimbusds.common.config.LoggableConfiguration

    LOG_CATEGORY
  • Constructor Summary

    Constructors
    Constructor
    Description
    Creates a new web service details instance from the specified properties.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    log()
    Logs the configuration details at INFO level.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • url

      public final URL url
      The HTTP(S) URL of the web service.

      Property key: [prefix]url

    • trustSelfSignedCerts

      public final boolean trustSelfSignedCerts
      Specifies whether to accept self-signed X.509 certificates presented by the web service (for HTTPS connections).

      Property key: [prefix]trustSelfSignedCerts

    • DEFAULT_SELF_SIGNED_CERT_TRUST

      public static final boolean DEFAULT_SELF_SIGNED_CERT_TRUST
      The default self-signed certificate policy.
      See Also:
    • connectTimeout

      public final int connectTimeout
      Specifies an HTTP connect timeout for web service requests, in milliseconds. Zero implies the option is disabled (timeout of infinity).

      Property key: [prefix]connectTimeout

    • DEFAULT_CONNECT_TIMEOUT

      public static final int DEFAULT_CONNECT_TIMEOUT
      The default HTTP connect timeout for web service requests (disabled).
      See Also:
    • readTimeout

      public final int readTimeout
      Specifies an HTTP read timeout for web service requests, in milliseconds. Zero implies the option is disabled (timeout of infinity).

      Property key: [prefix]readTimeout

    • DEFAULT_READ_TIMEOUT

      public static final int DEFAULT_READ_TIMEOUT
      The default HTTP read timeout for web service requests (disabled).
      See Also:
    • apiKey

      public final String apiKey
      Optional API key to include with requests to the web service, null if none.

      Property key: [prefix]apiKey

  • Constructor Details

    • WebServiceDetails

      public WebServiceDetails(String prefix, Properties props) throws com.thetransactioncompany.util.PropertyParseException
      Creates a new web service details instance from the specified properties.

      Mandatory properties:

      • [prefix]url

      Optional properties, with defaults:

      • [prefix]trustSelfSignedCerts = false
      • [prefix]connectTimeout = 0
      • [prefix]readTimeout = 0
      • [prefix]apiKey = null
      Parameters:
      prefix - The properties prefix. Must not be null.
      props - The properties. Must not be null.
      Throws:
      com.thetransactioncompany.util.PropertyParseException - On a missing or invalid property.
  • Method Details