All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.openxc.measurements.FuelLevel Maven / Gradle / Ivy

The newest version!
package com.openxc.measurements;

import com.openxc.units.Percentage;
import com.openxc.util.Range;

/**
 * The FuelLevel is the current level of fuel in the gas tank.
 */
public class FuelLevel extends BaseMeasurement {
    private final static Range RANGE =
        new Range(new Percentage(0), new Percentage(100));
    public final static String ID = "fuel_level";

    public FuelLevel(Number value) {
        super(new Percentage(value), RANGE);
    }

    public FuelLevel(Percentage value) {
        super(value, RANGE);
    }

    @Override
    public String getGenericName() {
        return ID;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy