Package xal.ca

Class ChannelTimeRecordImpl

All Implemented Interfaces:
ChannelRecord, ChannelStatusRecord, ChannelTimeRecord

public class ChannelTimeRecordImpl extends ChannelStatusRecordImpl implements ChannelTimeRecord
ChannelTimeRecord is a wrapper for channel data that has a value along with status information and a time stamp.
Author:
tap
  • Field Details

  • Constructor Details

    • ChannelTimeRecordImpl

      public ChannelTimeRecordImpl(TimeAdaptor adaptor)
      Creates new ChannelTimeRecord
      Parameters:
      adaptor - from which to generate the record
  • Method Details

    • getTimestamp

      public Timestamp getTimestamp()
      Get the timestamp.
      Specified by:
      getTimestamp in interface ChannelTimeRecord
      Returns:
      the timestamp
    • timeStampInSeconds

      public double timeStampInSeconds()
      Get the time stamp in seconds since the Java epoch epoch. Some precision is lost as we move away from the epoch since the double precision number cannot hold the full native precision.
      Specified by:
      timeStampInSeconds in interface ChannelTimeRecord
      Returns:
      The time stamp in seconds as a double.
    • toString

      public String toString()
      Override the inherited method to return a description of this object.
      Specified by:
      toString in interface ChannelRecord
      Overrides:
      toString in class ChannelStatusRecordImpl
      Returns:
      A description of this object.