Package com.dsi.ant.message
Class ExtendedData
java.lang.Object
com.dsi.ant.message.ExtendedData
ExtendedData
contains data members parsed from extended messages. Stores default values unless an extended
data is received to set.- Since:
- 4.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionfinal class
The flags in the raw flag byte, which indicate what data is held within the extended message. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
The index at which the flag byte is within AntMessage contents for flagged extended messages. -
Constructor Summary
ConstructorsConstructorDescriptionExtendedData
(DataMessage dataMessage) Constructs the Extended Data object from a received data message. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Gets the channel ID in the extended data.getRssi()
Gets the RSSI data in the extended data.Gets the timestamp in the extended databoolean
Checks if channel ID is included in the extended data.static boolean
hasExtendedData
(AntMessageFromAnt antMessage) Checks if the received message from ANT contains extended data.int
hashCode()
boolean
hasRssi()
Checks if RSSI data is included in the extended data.boolean
Checks if timestamp is included in the extended data.toString()
-
Field Details
-
OFFSET_FLAG_BYTE
public static final int OFFSET_FLAG_BYTEThe index at which the flag byte is within AntMessage contents for flagged extended messages.- Since:
- 4.0
- See Also:
-
-
Constructor Details
-
ExtendedData
Constructs the Extended Data object from a received data message.- Parameters:
dataMessage
- A data message received from ANT.- Since:
- 4.0
-
-
Method Details
-
hasExtendedData
Checks if the received message from ANT contains extended data.- Parameters:
antMessage
- The message received from ANT.- Returns:
- True, if the message contains extended data. False, otherwise.
- Since:
- 4.0
-
hasChannelId
public boolean hasChannelId()Checks if channel ID is included in the extended data.- Returns:
- True, if extended data has channel ID. False, otherwise.
- Since:
- 4.0
-
hasRssi
public boolean hasRssi()Checks if RSSI data is included in the extended data.- Returns:
- True, if extended data has RSSI information. False, otherwise.
- Since:
- 4.0
-
hasTimestamp
public boolean hasTimestamp()Checks if timestamp is included in the extended data.- Returns:
- True, if extended data has timestamp. False, otherwise.
- Since:
- 4.0
-
getChannelId
Gets the channel ID in the extended data.- Returns:
- null if the extended data does not contain Channel ID information
- Since:
- 4.0
-
getRssi
Gets the RSSI data in the extended data.- Returns:
- null if the extended data does not contain RSSI information
- Since:
- 4.0
-
getTimestamp
Gets the timestamp in the extended data- Returns:
- null if the extended data does not contain Timestamp information
- Since:
- 4.0
-
hashCode
public int hashCode() -
equals
-
toString
-