Skip to main content

Layer1ApiRequestCurrentTimeEvents

Package: velox.api.layer1.messages

Type: Class

Inheritance: java.lang.Object รขโ€ โ€™ Layer1ApiRequestCurrentTimeEvents

Descriptionโ€‹

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.

Fieldsโ€‹

BOOKMAP_INTERVAL_NSโ€‹

public static final long BOOKMAP_INTERVAL_NS

BOOKMAP_USER_MESSAGEโ€‹

public static final Layer1ApiRequestCurrentTimeEvents BOOKMAP_USER_MESSAGE

This message is always used by core for CurrentTimeUserMessage.

MIN_INTERVAL_NSโ€‹

public static final long MIN_INTERVAL_NS

startTimeNsโ€‹

public final long startTimeNs

intervalNsโ€‹

public final long intervalNs

isAddโ€‹

public boolean isAdd

Constructorsโ€‹

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)

Methodsโ€‹

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 String toString()

Overrides: toString in class Object