Class TimesyncHandler

java.lang.Object
org.openwms.common.comm.osip.synq.TimesyncHandler
All Implemented Interfaces:
Function<org.springframework.messaging.support.GenericMessage<TimesyncRequest>,Void>

@OSIPComponent class TimesyncHandler extends Object implements Function<org.springframework.messaging.support.GenericMessage<TimesyncRequest>,Void>
A TimesyncHandler.
Author:
Heiko Scherrer
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final org.openwms.common.comm.app.Channels
     
    private final org.openwms.common.comm.tcp.ConnectionHolder
     
    private final org.openwms.common.comm.TimeProvider
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    TimesyncHandler(org.openwms.common.comm.app.Channels channels, org.openwms.common.comm.tcp.ConnectionHolder connectionHolder, org.openwms.common.comm.TimeProvider timeProvider)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    apply(org.springframework.messaging.support.GenericMessage<TimesyncRequest> timesyncRequest)
    Builds response message with the current time and the same request header to preserve header information (seq. number etc.) in post transformation steps.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface java.util.function.Function

    andThen, compose
  • Field Details

    • channels

      private final org.openwms.common.comm.app.Channels channels
    • connectionHolder

      private final org.openwms.common.comm.tcp.ConnectionHolder connectionHolder
    • timeProvider

      private final org.openwms.common.comm.TimeProvider timeProvider
  • Constructor Details

    • TimesyncHandler

      TimesyncHandler(org.openwms.common.comm.app.Channels channels, org.openwms.common.comm.tcp.ConnectionHolder connectionHolder, org.openwms.common.comm.TimeProvider timeProvider)
  • Method Details

    • apply

      public Void apply(org.springframework.messaging.support.GenericMessage<TimesyncRequest> timesyncRequest)
      Builds response message with the current time and the same request header to preserve header information (seq. number etc.) in post transformation steps.
      Specified by:
      apply in interface Function<org.springframework.messaging.support.GenericMessage<TimesyncRequest>,Void>
      Parameters:
      timesyncRequest - the generic technology agnostic message object
      Returns:
      the response