Class NmeaMessage


  • public class NmeaMessage
    extends java.lang.Object
    Bean to carry NMEA fields.
    Author:
    dxm
    • Constructor Summary

      Constructors 
      Constructor Description
      NmeaMessage​(java.util.LinkedHashMap<java.lang.String,​java.lang.String> tags, java.util.List<java.lang.String> items, java.lang.String checksum)
      Constructor.
    • Constructor Detail

      • NmeaMessage

        public NmeaMessage​(java.util.LinkedHashMap<java.lang.String,​java.lang.String> tags,
                           java.util.List<java.lang.String> items,
                           java.lang.String checksum)
        Constructor.
        Parameters:
        tags - is a list of tags from the tag block section of an NMEA message
        items - is the list of columns from the NMEA message (not including the tag block) but including the checksum on the final column.
    • Method Detail

      • getSource

        public java.lang.String getSource()
        Returns the 's:' value from the tag block.
        Returns:
      • getUnixTimeMillis

        public java.lang.Long getUnixTimeMillis()
        Returns the 'c:' value from the tag block times 1000 to convert to millis. Returns null if not present.
        Returns:
      • getDestination

        public java.lang.String getDestination()
        Returns the 'd:' value from the tag block.
        Returns:
      • getSentenceGroupingFromTagBlock

        public java.lang.String getSentenceGroupingFromTagBlock()
        Returns the 'g:' value from the tag block.
        Returns:
      • getLineCount

        public java.lang.Integer getLineCount()
        Returns the 'n:' value from the tag block.
        Returns:
      • getRelativeTimeMillis

        public java.lang.Long getRelativeTimeMillis()
        Returns the 'r:' value from the tag block times 1000 to convert to millis.
        Returns:
      • getText

        public java.lang.String getText()
        Returns the 't:' value from the tag block.
        Returns:
      • getItems

        public java.util.List<java.lang.String> getItems()
        Returns a list of the NMEA items from the columns after the tag block.
        Returns:
      • getTags

        public java.util.LinkedHashMap<java.lang.String,​java.lang.String> getTags()
      • getTalker

        public Talker getTalker()
      • toLine

        public java.lang.String toLine()
      • getSentenceNumber

        public java.lang.Integer getSentenceNumber()
      • getSentenceCount

        public java.lang.Integer getSentenceCount()
      • getSentenceGroupId

        public java.lang.String getSentenceGroupId()
      • calculateChecksum

        public java.lang.String calculateChecksum()
        Returns a recalculated checksum.
        Returns:
        calculated checksum
      • getChecksum

        public java.lang.String getChecksum()
      • isSingleSentence

        public boolean isSingleSentence()
      • getArrivalTimeMillis

        public java.lang.Long getArrivalTimeMillis()