public interface KartStatusRegisterListener
Low-level interface in order to get changes from the remote kart represented by a Kart
instance.
Implement this interface if you like to get notified about all possible kart status registers that have been send from the kart to the application. If
you are interested only to the steering position or the battery level, you can implement the much simpler to use KartListener
interface. Your class
or your classes can even implement both interfaces, the Kart class supports multiple listeners registered at the same time.
Modifier and Type | Method and Description |
---|---|
void |
statusRegisterHasChanged(Kart kart,
KartStatusRegister register,
int newValue)
This method is called by a
Kart instance to which this listener has been registered for every register that changed it's value. |
void statusRegisterHasChanged(Kart kart, KartStatusRegister register, int newValue)
This method is called by a Kart
instance to which this listener has been registered for every register that changed it's value. Note
that this method is called just before the local register storage will be updated. This enables you to access the old value using the method
Kart.getStatusRegisterSigned(KartStatusRegister)
respective the method Kart.getStatusRegisterUnsigned(KartStatusRegister)
.
kart
- The Kart instance holding the register that has changed.register
- Identifier of the register that has changed.newValue
- The new value of the register.