Class CmsBroadcastTimer


  • public class CmsBroadcastTimer
    extends java.lang.Object
    A timer which sends an RPC call regularly to keep the session alive and receive workplace broadcasts.

    Since:
    9.5.0
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int PING_INTERVAL
      The interval for the RPC calls.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static void abort()
      Aborts the timer.
      protected java.lang.String createMessageHtml​(org.opencms.gwt.shared.CmsBroadcastMessage message)
      Generates the HTML for a single broadcast message.
      protected void run()
      Installs the timer which fires the RPC calls.
      protected static boolean shouldKeepRunning()
      Returns if the timer should keep running.
      static void start()
      Starts the timer.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • abort

        public static void abort()
        Aborts the timer.

      • start

        public static void start()
        Starts the timer.

      • shouldKeepRunning

        protected static boolean shouldKeepRunning()
        Returns if the timer should keep running.

        Returns:
        true if the ping timer should keep running
      • createMessageHtml

        protected java.lang.String createMessageHtml​(org.opencms.gwt.shared.CmsBroadcastMessage message)
        Generates the HTML for a single broadcast message.

        Parameters:
        message - the message
        Returns:
        the HTML string
      • run

        protected void run()
        Installs the timer which fires the RPC calls.