org.discotools.io.aprs
Class AprsParser

java.lang.Object
  extended by org.discotools.io.AbstractParser<AprsReport>
      extended by org.discotools.io.aprs.AprsParser
All Implemented Interfaces:
org.discotools.io.Parser<AprsReport>

public final class AprsParser
extends org.discotools.io.AbstractParser<AprsReport>

Default APRS Report parser.

This parser captures the following information about the sender

  • His callsign
  • His operation path
  • his approximate location
  • What was in his last packet
  • The parser algorithm implements the pseudo-code published by the father of APRS, Bob Bruninga (WB4APR).

    The vicinity plot algorithm suggested by Bruninga, which calculate an approximate location of stations with no prior location data registered, is also supported. The vicinity plot algorithm utilize location data of the first known digipeaters found on the operation path to calculate an approximate location.

    This parser uses the APRS Vicinity Plotting Algorithm to assign an location based on the location of the first known digipeater and igate that heard the station. see the APRS parser pseudo-code for more information on how to implement the algorithm.

    Each station recognized by the parser is stored in an station cache supplied at construction. If no external cache is supplied an internal instance is used instead.

    Author:
    kengu

    Constructor Summary
    AprsParser()
              Default constructor.
    AprsParser(AprsCache cache)
              External cache constructor.
     
    Method Summary
     void addListener(AprsCacheListener listener)
               
     AprsCache getCache()
               
     List<AprsReport> parse(String payload)
               
     void removeListener(AprsCacheListener listener)
               
     
    Methods inherited from class java.lang.Object
    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
     

    Constructor Detail

    AprsParser

    public AprsParser()
    Default constructor.


    AprsParser

    public AprsParser(AprsCache cache)
    External cache constructor.

    Parameters:
    cache - - AprsCache instance
    Method Detail

    getCache

    public AprsCache getCache()

    addListener

    public void addListener(AprsCacheListener listener)

    removeListener

    public void removeListener(AprsCacheListener listener)

    parse

    public List<AprsReport> parse(String payload)
                           throws org.discotools.io.ParseException
    Specified by:
    parse in interface org.discotools.io.Parser<AprsReport>
    Specified by:
    parse in class org.discotools.io.AbstractParser<AprsReport>
    Throws:
    org.discotools.io.ParseException


    Copyright © 2012-2013 DISCO Foundation. All Rights Reserved.