Package au.gov.amsa.ais.message
Class AisPositionA
- java.lang.Object
-
- au.gov.amsa.ais.message.AisPositionA
-
- All Implemented Interfaces:
AisMessage,HasCommunications,HasMmsi,HasNavigationalStatus,AisPosition
public class AisPositionA extends java.lang.Object implements AisPosition, HasCommunications, HasNavigationalStatus
Decoder for AIS message types 1, 2,3 (Class A position reports).- Author:
- dxm
-
-
Constructor Summary
Constructors Constructor Description AisPositionA(AisExtractorFactory factory, java.lang.String message, java.lang.String source, int padBits)AisPositionA(java.lang.String message, int padBits)AisPositionA(java.lang.String message, java.lang.String source, int padBits)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CommunicationsgetCommunications()Returns the communications part of an AIS Message.java.lang.DoublegetCourseOverGround()java.lang.DoublegetLatitude()java.lang.DoublegetLongitude()intgetMessageId()Returns the ais message id.intgetMmsi()NavigationalStatusgetNavigationalStatus()java.lang.IntegergetRateOfTurn()intgetRepeatIndicator()java.lang.StringgetSource()Returns the source of the ais message.intgetSpare()intgetSpecialManoeuvreIndicator()java.lang.DoublegetSpeedOverGroundKnots()intgetTimeSecondsOnly()java.lang.IntegergetTrueHeading()booleanisHighAccuracyPosition()booleanisUsingRAIM()java.lang.StringtoString()
-
-
-
Constructor Detail
-
AisPositionA
public AisPositionA(java.lang.String message, java.lang.String source, int padBits)
-
AisPositionA
public AisPositionA(java.lang.String message, int padBits)
-
AisPositionA
public AisPositionA(AisExtractorFactory factory, java.lang.String message, java.lang.String source, int padBits)
-
-
Method Detail
-
getMessageId
public int getMessageId()
Description copied from interface:AisMessageReturns the ais message id. For example Class A Position reports are either 1, 2, or 3.- Specified by:
getMessageIdin interfaceAisMessage- Returns:
-
getRepeatIndicator
public int getRepeatIndicator()
- Specified by:
getRepeatIndicatorin interfaceAisPosition
-
getNavigationalStatus
public NavigationalStatus getNavigationalStatus()
- Specified by:
getNavigationalStatusin interfaceHasNavigationalStatus
-
getRateOfTurn
public java.lang.Integer getRateOfTurn()
-
getSpeedOverGroundKnots
public java.lang.Double getSpeedOverGroundKnots()
- Specified by:
getSpeedOverGroundKnotsin interfaceAisPosition
-
isHighAccuracyPosition
public boolean isHighAccuracyPosition()
- Specified by:
isHighAccuracyPositionin interfaceAisPosition
-
getLongitude
public java.lang.Double getLongitude()
- Specified by:
getLongitudein interfaceAisPosition
-
getLatitude
public java.lang.Double getLatitude()
- Specified by:
getLatitudein interfaceAisPosition
-
getCourseOverGround
public java.lang.Double getCourseOverGround()
- Specified by:
getCourseOverGroundin interfaceAisPosition
-
getTrueHeading
public java.lang.Integer getTrueHeading()
- Specified by:
getTrueHeadingin interfaceAisPosition
-
getTimeSecondsOnly
public int getTimeSecondsOnly()
- Specified by:
getTimeSecondsOnlyin interfaceAisPosition
-
getSpecialManoeuvreIndicator
public int getSpecialManoeuvreIndicator()
-
getSpare
public int getSpare()
-
isUsingRAIM
public boolean isUsingRAIM()
- Specified by:
isUsingRAIMin interfaceAisPosition
-
getCommunications
public Communications getCommunications()
Description copied from interface:HasCommunicationsReturns the communications part of an AIS Message.- Specified by:
getCommunicationsin interfaceHasCommunications- Returns:
-
getSource
public java.lang.String getSource()
Description copied from interface:AisMessageReturns the source of the ais message. The source is not available in the ais message itself but may be provided in the tag block of the NMEA message that contains the ais message.- Specified by:
getSourcein interfaceAisMessage- Returns:
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-