Interface UniversalisWs

All Known Implementing Classes:
UniversalisWsImpl

public interface UniversalisWs
Interface for universalis websocket implementation.
  • Method Details

    • subscribe

      void subscribe(Subscription subscription)
      Add a subscription.
      Parameters:
      subscription - subcription to add
    • unsubscribe

      void unsubscribe(Subscription subscription)
      Remove a subscription.
      Parameters:
      subscription - subscription to remove
    • disconnect

      void disconnect()
      Disconnect the websocket. Once disconnected the socket can no longer be used.
    • awaitReady

      void awaitReady()
      Suspends the thread until the websocket is connected.
    • websocketBuilder

      static WebsocketFactoryBuilder websocketBuilder()
      Get a websocket builder. Use this if you want more control about the socket itself.

      Use getDefault() if your don't know that this means.

      Returns:
      websocket factory builder
    • getDefault

      static UniversalisWsBuilder getDefault()
      Get a universalis builder for websockets.
      Returns:
      universalis websocket builder