接口 RTESentence

所有超级接口:
Sentence

public interface RTESentence extends Sentence
GPS route data and list of waypoints.

Example:
$GPRTE,1,1,c,0,MELIN,RUSKI,KNUDAN*25

作者:
Kimmo Tuukkanen
  • 方法详细资料

    • addWaypointId

      int addWaypointId(String id)
      Add a waypoint ID at the end of waypoint list. The number of waypoint id fields is increased by one on each addition.
      参数:
      id - Waypoint ID to add.
      返回:
      The total number of waypoint IDs after addition.
    • getRouteId

      String getRouteId()
      Get the number or name of the route.
      返回:
      Route ID or name as String
      抛出:
      DataNotAvailableException - If the data is not available.
      ParseException - If the field contains unexpected or illegal value.
    • getSentenceCount

      int getSentenceCount()
      Get the number of sentences in RTE sequence.
      返回:
      integer
      抛出:
      DataNotAvailableException - If the data is not available.
      ParseException - If the field contains unexpected or illegal value.
      另请参阅:
    • getSentenceIndex

      int getSentenceIndex()
      Get the index of sentence in RTE sequence.
      返回:
      integer
      抛出:
      DataNotAvailableException - If the data is not available.
      ParseException - If the field contains unexpected or illegal value.
      另请参阅:
    • getWaypointCount

      int getWaypointCount()
      Get the number of waypoints IDs in this sentence.
      返回:
      Waypoint count
      抛出:
      DataNotAvailableException - If the data is not available.
      ParseException - If the field contains unexpected or illegal value.
    • getWaypointIds

      String[] getWaypointIds()
      Get the list of route waypoints.
      返回:
      Waypoint IDs as String array
      抛出:
      DataNotAvailableException - If the data is not available.
      ParseException - If the field contains unexpected or illegal value.
    • isActiveRoute

      boolean isActiveRoute()
      Tells if the sentence holds a current active route data.
      返回:
      true if active route, otherwise false.
      抛出:
      DataNotAvailableException - If the data is not available.
      ParseException - If the field contains unexpected or illegal value.
    • isFirst

      boolean isFirst()
      Tells if this is the first sentence in RTE sequence.
      返回:
      true if there's no sentences left, otherwise false.
      抛出:
      DataNotAvailableException - If the sentence index or sentence count is not available.
      ParseException - If sentence index or count fields contain unexpected or illegal value.
    • isLast

      boolean isLast()
      Tells if this is the last sentence in RTE sequence.
      返回:
      true if there's no sentences left, otherwise false.
      抛出:
      DataNotAvailableException - If the sentence index or sentence count is not available.
      ParseException - If sentence index or count fields contain unexpected or illegal value.
    • isWorkingRoute

      boolean isWorkingRoute()
      Tells if the sentence holds a current working route data.
      返回:
      true if working route, otherwise false.
      抛出:
      DataNotAvailableException - If the data is not available.
      ParseException - If status field contains illegal value.
    • setRouteId

      void setRouteId(String id)
      Set the route name or number.
      参数:
      id - Route ID or name as String
    • setRouteType

      void setRouteType(RouteType type)
      Set the type of route.
      参数:
      type - RouteType to set
    • setSentenceCount

      void setSentenceCount(int count)
      Set the number of sentences in RTE sequence.
      参数:
      count - Sentence count in sequence
      抛出:
      IllegalArgumentException - If the specified count is negative.
    • setSentenceIndex

      void setSentenceIndex(int index)
      Set the index of sentence in RTE sequence.
      参数:
      index - Sentence index in sequence
      抛出:
      IllegalArgumentException - If specified index is negative.
    • setWaypointIds

      void setWaypointIds(String[] ids)
      Set the list of route waypoints.
      参数:
      ids - String array of waypoint IDs