Steve Paik | c36f8ee | 2017-11-09 16:05:37 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2017 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | package android.car; |
| 17 | |
| 18 | import android.annotation.IntDef; |
Kai | 1599ef8 | 2019-02-28 15:03:05 -0800 | [diff] [blame] | 19 | |
Steve Paik | c36f8ee | 2017-11-09 16:05:37 -0800 | [diff] [blame] | 20 | import java.lang.annotation.Retention; |
| 21 | import java.lang.annotation.RetentionPolicy; |
| 22 | |
| 23 | /** |
| 24 | * FuelType denotes the different fuels a vehicle may use. |
Steve Paik | c36f8ee | 2017-11-09 16:05:37 -0800 | [diff] [blame] | 25 | */ |
| 26 | public final class FuelType { |
| 27 | /** |
| 28 | * List of Fuel Types from VHAL |
| 29 | */ |
| 30 | public static final int UNKNOWN = 0; |
| 31 | /** Unleaded gasoline */ |
| 32 | public static final int UNLEADED = 1; |
| 33 | /** Leaded gasoline */ |
| 34 | public static final int LEADED = 2; |
Kai | 1599ef8 | 2019-02-28 15:03:05 -0800 | [diff] [blame] | 35 | /** #1 Grade Diesel */ |
Steve Paik | c36f8ee | 2017-11-09 16:05:37 -0800 | [diff] [blame] | 36 | public static final int DIESEL_1 = 3; |
Kai | 1599ef8 | 2019-02-28 15:03:05 -0800 | [diff] [blame] | 37 | /** #2 Grade Diesel */ |
Steve Paik | c36f8ee | 2017-11-09 16:05:37 -0800 | [diff] [blame] | 38 | public static final int DIESEL_2 = 4; |
| 39 | /** Biodiesel */ |
| 40 | public static final int BIODIESEL = 5; |
| 41 | /** 85% ethanol/gasoline blend */ |
| 42 | public static final int E85 = 6; |
| 43 | /** Liquified petroleum gas */ |
| 44 | public static final int LPG = 7; |
| 45 | /** Compressed natural gas */ |
| 46 | public static final int CNG = 8; |
| 47 | /** Liquified natural gas */ |
| 48 | public static final int LNG = 9; |
| 49 | /** Electric */ |
| 50 | public static final int ELECTRIC = 10; |
| 51 | /** Hydrogen fuel cell */ |
| 52 | public static final int HYDROGEN = 11; |
| 53 | /** |
| 54 | * Fuel type to use when no other types apply. Before using this value, work with |
| 55 | * Google to see if the FuelType enum can be extended with an appropriate value. |
| 56 | */ |
| 57 | public static final int OTHER = 12; |
| 58 | |
Kai | 48106a9 | 2018-12-18 13:26:19 -0800 | [diff] [blame] | 59 | /** @hide */ |
Steve Paik | c36f8ee | 2017-11-09 16:05:37 -0800 | [diff] [blame] | 60 | @IntDef({ |
| 61 | UNKNOWN, |
| 62 | UNLEADED, |
| 63 | LEADED, |
| 64 | DIESEL_1, |
| 65 | DIESEL_2, |
| 66 | BIODIESEL, |
| 67 | E85, |
| 68 | LPG, |
| 69 | CNG, |
| 70 | LNG, |
| 71 | ELECTRIC, |
| 72 | HYDROGEN, |
| 73 | OTHER |
| 74 | }) |
Kai | 48106a9 | 2018-12-18 13:26:19 -0800 | [diff] [blame] | 75 | @Retention(RetentionPolicy.SOURCE) |
Steve Paik | c36f8ee | 2017-11-09 16:05:37 -0800 | [diff] [blame] | 76 | public @interface Enum {} |
| 77 | |
Steve Paik | c36f8ee | 2017-11-09 16:05:37 -0800 | [diff] [blame] | 78 | private FuelType() {} |
| 79 | } |