Interface DynamicRestClient

All Known Implementing Classes:
DynamicCsvImportClient, DynamicPoolActionClient, DynamicPublicationClient

public interface DynamicRestClient
A REST client, which can connect to different servers.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns URL of the API root for the current server to use.
    void
    Instructs this client to stop using a server explicitly specified previously and to start using the server selected in the DataHub UI.
    void
    Specifies DataHub server to use for uploading data.
  • Method Details

    • useServer

      void useServer(DataHubServer server)
      Specifies DataHub server to use for uploading data. The server will be used until another server is not specified or this client is instructed to use the default context server.
      Parameters:
      server - a server, against which the REST calls should be executed.
    • useContextServer

      void useContextServer()
      Instructs this client to stop using a server explicitly specified previously and to start using the server selected in the DataHub UI.
      See Also:
    • getBaseApiUrl

      String getBaseApiUrl()
      Returns URL of the API root for the current server to use.
      Returns:
      URL string for the REST API base. All request should be constructed relative to this base URL.