Class Layer1ApiRequestCurrentTimeEvents

java.lang.Object
velox.api.layer1.messages.Layer1ApiRequestCurrentTimeEvents

public class Layer1ApiRequestCurrentTimeEvents
extends java.lang.Object
Providers time will be sent using CurrentTimeUserMessage at least as often as specified by interval There is one exception: if system was in sleep mode or system time was changed while bookmap was working, some events might be skipped, and event with CurrentTimeUserMessage.isEventsSkipped = true flag will be sent
  • Field Summary

    Fields 
    Modifier and Type Field Description
    long intervalNs  
    boolean isAdd  
    static long MIN_INTERVAL_NS  
    long startTimeNs  
  • Constructor Summary

    Constructors 
    Constructor Description
    Layer1ApiRequestCurrentTimeEvents​(boolean isAdd, long startTimeNs, long intervalNs)  
  • Method Summary

    Modifier and Type Method Description
    long getIntervalNs()  
    void setAdd​(boolean isAdd)  
    java.lang.String toString()  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

  • Constructor Details

    • Layer1ApiRequestCurrentTimeEvents

      public Layer1ApiRequestCurrentTimeEvents​(boolean isAdd, long startTimeNs, long intervalNs)
      Parameters:
      isAdd - true if message wants to start receiving current time messages, false if to stop
      startTimeNs - time of first message sent in UTC nanoseconds
      intervalNs - in nanoseconds, at least 1 time message will be sent in every interval
      0 if you only want one message to be sent (can't be less than MIN_INTERVAL_NS)
  • Method Details

    • getIntervalNs

      public long getIntervalNs()
    • setAdd

      public void setAdd​(boolean isAdd)
      Parameters:
      isAdd - true if message wants to start receiving current time messages, false if to stop
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object