-
Notifications
You must be signed in to change notification settings - Fork 118
Open
Labels
future workIssues that are not high on the priority list.Issues that are not high on the priority list.
Milestone
Description
The parent class provides a standard interface for all measurements, starting
with a way to determine if a specific data type is supported by the vehicle
you're running on:
if(vehicleService.supports(VehicleSpeed.class) {
// it supports it
} else {
// if we try to get it and it doesn't support it, we throw an
// UnsupportedMeasurementException
vehicleService.get(VehicleSpeed.class);
/* boom */
}
Some measurements may be supported, but may not have been received from the CAN
translator yet - it could be a malfunction, or you're just checking too early
for an infrequently updated measurement:
if(vehicleService.supports(VehicleSpeed.class) {
VehicleSpeed measurement = vehicleService.get(VehicleSpeed.class);
if(measurement.isNone()) {
// do stuff with it
}
}
Metadata
Metadata
Assignees
Labels
future workIssues that are not high on the priority list.Issues that are not high on the priority list.