Package com.oorian

Enum Class CommunicationMode

java.lang.Object
java.lang.Enum<CommunicationMode>
com.oorian.CommunicationMode
All Implemented Interfaces:
Serializable, Comparable<CommunicationMode>, Constable

public enum CommunicationMode extends Enum<CommunicationMode>
Defines the asynchronous communication mode used between the browser and server for an HtmlPage.
  • APP_DEFAULT - Use the application-wide default communication mode
  • AJAX_ONLY - Request/response polling with no persistent connection
  • AJAX_WITH_SSE - AJAX for client-to-server events, Server-Sent Events for server-to-client push
  • WEBSOCKET - Full-duplex bidirectional communication
  • Enum Constant Details

    • APP_DEFAULT

      public static final CommunicationMode APP_DEFAULT
      Use the application-wide default communication mode set via Application.setDefaultCommunicationMode(CommunicationMode).
    • AJAX_ONLY

      public static final CommunicationMode AJAX_ONLY
      Poll-based communication with no persistent connection. Client sends AJAX requests and server responds. Server-initiated updates must be queued until the next client request.
    • AJAX_WITH_SSE

      public static final CommunicationMode AJAX_WITH_SSE
      Hybrid mode using AJAX for client-to-server communication and Server-Sent Events (SSE) for server-to-client push notifications. SSE provides automatic reconnection and works through most proxies and firewalls.
    • WEBSOCKET

      public static final CommunicationMode WEBSOCKET
      Full-duplex bidirectional WebSocket communication. This is the default mode and provides the lowest latency for real-time applications.
  • Method Details

    • values

      public static CommunicationMode[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static CommunicationMode valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null