接口 BODSentence
- 所有超级接口:
Sentence
True and magnetic bearing from origin to destination in degrees. This
sentence is transmitted by a GPS in the GOTO mode (with or without active
route).
Example:
$GPBOD,234.9,T,228.8,M,RUSKI,*1D
- 作者:
- Kimmo Tuukkanen
-
字段概要
从接口继承的字段 net.sf.marineapi.nmea.sentence.Sentence
ALTERNATIVE_BEGIN_CHAR, BEGIN_CHAR, CHECKSUM_DELIMITER, FIELD_DELIMITER, MAX_LENGTH, TERMINATOR -
方法概要
修饰符和类型方法说明Get the ID of destination waypoint.doubleGet the magnetic bearing from origin to destination.Get the ID of origin waypoint.doubleGet the true bearing from origin to destination.voidSets the destination waypoint ID.voidsetMagneticBearing(double bearing) Sets the true bearing from origin to destination, in degrees.voidSets the ID of origin waypoint.voidsetTrueBearing(double bearing) Sets the true bearing from origin to destination, in degrees.从接口继承的方法 net.sf.marineapi.nmea.sentence.Sentence
getBeginChar, getFieldCount, getSentenceId, getTalkerId, isAISSentence, isProprietary, isValid, reset, setBeginChar, setTalkerId, toSentence, toSentence, toString
-
方法详细资料
-
getDestinationWaypointId
String getDestinationWaypointId()Get the ID of destination waypoint. This field should be always available in GOTO mode.- 返回:
- waypoint id
- 抛出:
DataNotAvailableException- If the data is not available.ParseException- If the field contains unexpected or illegal value.
-
getMagneticBearing
double getMagneticBearing()Get the magnetic bearing from origin to destination.Notice: The bearing is calculated from the origin when GOTO is activated and it is not updated dynamically.
- 返回:
- magnetic bearing value
- 抛出:
DataNotAvailableException- If the data is not available.ParseException- If the field contains unexpected or illegal value.
-
getOriginWaypointId
String getOriginWaypointId()Get the ID of origin waypoint. This field is available only when route is active.- 返回:
- waypoint id
- 抛出:
DataNotAvailableException- If the data is not available.ParseException- If the field contains unexpected or illegal value.
-
getTrueBearing
double getTrueBearing()Get the true bearing from origin to destination.Notice: Typically the bearing is calculated when GOTO mode is activated and it is not updated dynamically.
- 返回:
- True bearing
- 抛出:
DataNotAvailableException- If the data is not available.ParseException- If the field contains unexpected or illegal value.
-
setDestinationWaypointId
Sets the destination waypoint ID.- 参数:
id- ID to set
-
setMagneticBearing
void setMagneticBearing(double bearing) Sets the true bearing from origin to destination, in degrees.- 参数:
bearing- Bearing value- 抛出:
IllegalArgumentException- If bearing value out range 0..360 degrees.
-
setOriginWaypointId
Sets the ID of origin waypoint.- 参数:
id- ID to set.
-
setTrueBearing
void setTrueBearing(double bearing) Sets the true bearing from origin to destination, in degrees.- 参数:
bearing- Bearing value- 抛出:
IllegalArgumentException- If bearing value out range 0..360 degrees.
-