Class BaseSyncClient

    • Field Detail

      • clientCommonLibraryVersion

        public final String clientCommonLibraryVersion
        Compatible SDK version, provided by the codegen.
      • minimumClientCommonLibraryVersionFromClient

        public final Optional<String> minimumClientCommonLibraryVersionFromClient
        Minimum compatible SDK version, maybe provided by the codegen.
    • Method Detail

      • useRealmSpecificEndpointTemplate

        public void useRealmSpecificEndpointTemplate​(boolean useOfRealmSpecificEndpointTemplateEnabled)
        This method should be used to enable or disable the use of realm-specific endpoint template.

        The default value is null. To enable the use of endpoint template defined for the realm in use, set the flag to true To disable the use of endpoint template defined for the realm in use, set the flag to false

        Parameters:
        useOfRealmSpecificEndpointTemplateEnabled - This flag can be set to true or false to enable or disable the use of realm-specific endpoint template respectively
      • populateServiceParametersInEndpoint

        public final void populateServiceParametersInEndpoint​(String endpoint,
                                                              Map<String,​Object> requiredParametersMap)
        Populate the parameters in the endpoint with its corresponding value and update the base endpoint.

        The value will be populated iff the parameter in endpoint is a required request path parameter or a required request query parameter. If not, the parameter in the endpoint will be ignored and left blank.

        Parameters:
        endpoint - The endpoint template in use
        requiredParametersMap - Map of parameter name as key and value set in request path or query parameter as value
      • updateBaseEndpoint

        public final void updateBaseEndpoint​(String endpoint)
        This method should be used for parameterized endpoint templates only.

        This does not include {region} and {secondLevelDomain} parameters.

        Parameters:
        endpoint - The updated endpoint to use
      • setEndpoint

        public final void setEndpoint​(String endpoint)
      • getEndpoint

        public final String getEndpoint()
      • refreshClient

        public final void refreshClient()
        Rebuild the backing HttpClient.

        This will call ClientConfigurators again, and can be used to e.g. refresh the SSL certificate.

      • setRegion

        protected void setRegion​(Region region)
      • setRegion

        protected void setRegion​(String regionId)
      • getClientCommonLibraryVersion

        public String getClientCommonLibraryVersion()
      • getMinimumClientCommonLibraryVersionFromClient

        public Optional<String> getMinimumClientCommonLibraryVersionFromClient()