1 package au.gov.amsa.ais; 2 3 /** 4 * Receives the results of Nmea stream processing. 5 * 6 * @author dxm 7 * 8 */ 9 public interface NmeaStreamProcessorListener { 10 11 /** 12 * Message has arrived with given timestamp. 13 * 14 * @param line 15 * nmea line 16 * @param time 17 * in epoch ms 18 */ 19 void message(String line, long time); 20 21 /** 22 * Message has arrived and could not be associated with a timestamp other 23 * than the arrival time. 24 * 25 * @param line 26 * nmea line 27 * @param arrivalTime 28 * in epoch ms 29 */ 30 void timestampNotFound(String line, Long arrivalTime); 31 32 /** 33 * Message has arrived that could not be parsed. 34 * 35 * @param line 36 * nmea line 37 * @param arrivalTime 38 * in epoch ms 39 * @param message 40 * the parse error message 41 */ 42 void invalidNmea(String line, long arrivalTime, String message); 43 }