Class DefaultLongPollingComet

java.lang.Object
org.eclnt.jsfserver.polling.comet.DefaultLongPollingComet
All Implemented Interfaces:
Serializable, ILongPolling

public class DefaultLongPollingComet extends Object implements ILongPolling, Serializable
See Also:
  • Constructor Details

    • DefaultLongPollingComet

      public DefaultLongPollingComet()
  • Method Details

    • getId

      public String getId()
      Specified by:
      getId in interface ILongPolling
    • getContinuePolling

      public boolean getContinuePolling()
      Specified by:
      getContinuePolling in interface ILongPolling
    • getURL

      public String getURL()
      Description copied from interface: ILongPolling
      URL that is addressed by the long polling component on client side.
      Specified by:
      getURL in interface ILongPolling
    • waitForEvent

      public boolean waitForEvent(javax.servlet.http.HttpServletResponse response, org.apache.catalina.comet.CometEvent event)
    • wakeup

      public void wakeup(boolean continuePolling)
      Description copied from interface: ILongPolling
      When an event is triggered then the wakeup method is to be called. This will send the response to the client side. This is the method to be called by your application in order to trigger the response.
      Specified by:
      wakeup in interface ILongPolling
    • wakeupForReconnect

      public void wakeupForReconnect()
      Description copied from interface: ILongPolling
      Calling this method will trigger the long polling to pass back a reconnect-signal to the client side. On client side the long polling will rebuild a new connection to the server side and continue the long polling.
      Specified by:
      wakeupForReconnect in interface ILongPolling
    • abortThread

      public void abortThread()
      Description copied from interface: ILongPolling
      Abort long polling thread.
      Specified by:
      abortThread in interface ILongPolling
    • abortThreadWithErrorIfWaiting

      public void abortThreadWithErrorIfWaiting()
      Description copied from interface: ILongPolling
      Abort long polling thread with error.
      Specified by:
      abortThreadWithErrorIfWaiting in interface ILongPolling
    • abortThreadWithouContinuingPolling

      public void abortThreadWithouContinuingPolling()
      Description copied from interface: ILongPolling
      Abort long polling thread - and tell the client that it should not continue to create new poll requests.
      Specified by:
      abortThreadWithouContinuingPolling in interface ILongPolling
    • keepAlive

      public void keepAlive()
      Description copied from interface: ILongPolling
      Writes some chunk content into the connection so that the connection is not timed out.
      Specified by:
      keepAlive in interface ILongPolling
    • getLastResponseTime

      public long getLastResponseTime()
      Description copied from interface: ILongPolling
      Point of time when a response activity (e.g. wakeup, wakeupForReconnect, ...) was executed.
      Specified by:
      getLastResponseTime in interface ILongPolling