public static AisMessage DecodeAis(NmeaMessage nmeaMsg) { if (nmeaMsg.NumberOfSentences > 1) { throw new Exception("Multipart message. Use GetAisMessage(List<NmeaMessage>) instead"); } return(AisParser.DecodeAisString(nmeaMsg.EncodedPayload)); }
public static AisMessage DecodeAis(List <NmeaMessage> nmeaMsg) { var encodedPayload = string.Empty; foreach (var msg in nmeaMsg) { encodedPayload += msg.EncodedPayload; } return(AisParser.DecodeAisString(encodedPayload)); }