Class ConnectionIndicator


  • public class ConnectionIndicator
    extends Object
    GWT interface to ConnectionIndicator.ts
    Since:
    1.0
    Author:
    Vaadin Ltd
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static String CONNECTED
      Application is connected to server: last transaction over the wire (XHR / heartbeat / endpoint call) was successful.
      static String CONNECTION_LOST
      Application has been permanently disconnected due to browser receiving the 'offline' event, or the server not being reached after a number of reconnect attempts.
      static String LOADING
      Application is connected and Flow is loading application state from the server, or Fusion is waiting for an endpoint call to return.
      static String RECONNECTING
      Application has been temporarily disconnected from the server because the last transaction over the wire (XHR / heartbeat / endpoint call) resulted in a network error, or the browser has received the 'online' event and needs to verify reconnection with the server.
    • Field Detail

      • CONNECTED

        public static final String CONNECTED
        Application is connected to server: last transaction over the wire (XHR / heartbeat / endpoint call) was successful.
        See Also:
        Constant Field Values
      • LOADING

        public static final String LOADING
        Application is connected and Flow is loading application state from the server, or Fusion is waiting for an endpoint call to return.
        See Also:
        Constant Field Values
      • RECONNECTING

        public static final String RECONNECTING
        Application has been temporarily disconnected from the server because the last transaction over the wire (XHR / heartbeat / endpoint call) resulted in a network error, or the browser has received the 'online' event and needs to verify reconnection with the server. Flow is attempting to reconnect a configurable number of times before giving up.
        See Also:
        Constant Field Values
      • CONNECTION_LOST

        public static final String CONNECTION_LOST
        Application has been permanently disconnected due to browser receiving the 'offline' event, or the server not being reached after a number of reconnect attempts.
        See Also:
        Constant Field Values
    • Method Detail

      • setState

        public static void setState​(String state)
        Set the connection state to be displayed by the loading indicator.
        Parameters:
        state - the connection state
      • getState

        public static String getState()
        Get the connection state.
        Returns:
        the connection state
      • setProperty

        public static void setProperty​(String property,
                                       Object value)
        Set a property of the connection indicator component.
        Parameters:
        property - the property to set
        value - the value to set