public class IeStatusAndStatusChanges extends InformationElement
Constructor and Description |
---|
IeStatusAndStatusChanges(int value)
Creates a SCD (status and status change detection) information element.
|
Modifier and Type | Method and Description |
---|---|
boolean |
getStatus(int position)
Returns true if the status at the given position is ON(1) and false otherwise.
|
int |
getValue() |
boolean |
hasStatusChanged(int position)
Returns true if the status at the given position has changed and false otherwise.
|
java.lang.String |
toString() |
public IeStatusAndStatusChanges(int value)
value
- the bits of value represent the status and status changed bits. Bit1 (the least significant bit) of
value represents the first status changed detection bit. Bit17 of value represents the first status
bit.public int getValue()
public boolean getStatus(int position)
position
- the position in the status bitstring. Range: 1-16. Status 1 is bit 17 and status 16 is bit 32 of the
value returned by getValue()
.public boolean hasStatusChanged(int position)
position
- the position in the status changed bitstring. Range: 1-16. Status changed 1 is bit 1 and status 16 is
bit 16 of the value returned by getValue()
.public java.lang.String toString()
toString
in class java.lang.Object