net.sf.marineapi.nmea.sentence
Interface HeadingSentence

All Superinterfaces:
Sentence
All Known Subinterfaces:
HDGSentence, HDMSentence, HDTSentence, VHWSentence

public interface HeadingSentence
extends Sentence

Interface for sentences that provide vessel's true or magnetic heading.

Author:
Kimmo Tuukkanen

Field Summary
 
Fields inherited from interface net.sf.marineapi.nmea.sentence.Sentence
ALTERNATIVE_BEGIN_CHAR, BEGIN_CHAR, CHECKSUM_DELIMITER, FIELD_DELIMITER, MAX_LENGTH, TERMINATOR
 
Method Summary
 double getHeading()
          Returns the vessel's current heading.
 boolean isTrue()
          Tells if the heading returned and set by getHeading() and setHeading(double) methods is true or magnetic .
 void setHeading(double hdt)
          Sets the heading value.
 
Methods inherited from interface net.sf.marineapi.nmea.sentence.Sentence
getBeginChar, getFieldCount, getSentenceId, getTalkerId, isProprietary, isValid, reset, setBeginChar, setTalkerId, toSentence, toSentence, toString
 

Method Detail

getHeading

double getHeading()
Returns the vessel's current heading.

Returns:
Heading in degrees.
See Also:
isTrue()

isTrue

boolean isTrue()
Tells if the heading returned and set by getHeading() and setHeading(double) methods is true or magnetic .

Returns:
true if true heading, otherwise false for magnetic heading.

setHeading

void setHeading(double hdt)
Sets the heading value.

Parameters:
hdt - Heading in degrees
Throws:
IllegalArgumentException - If heading value out of range [0..360]
See Also:
isTrue()


Copyright (C) 2010-2014 Java Marine API authors. All Rights Reserved.