1 /* 2 * Copyright (C) 2018 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; 19 import android.car.annotation.AddedInOrBefore; 20 21 import java.lang.annotation.Retention; 22 import java.lang.annotation.RetentionPolicy; 23 24 /** 25 * Used by INFO_FUEL_DOOR_LOCATION/INFO_CHARGE_PORT_LOCATION to enumerate fuel door or 26 * ev port location. 27 * Use getProperty and setProperty in {@link android.car.hardware.property.CarPropertyManager} to 28 * set and get this VHAL property. 29 */ 30 public final class PortLocationType { 31 /** 32 * List of port location types 33 */ 34 @AddedInOrBefore(majorVersion = 33) 35 public static final int UNKNOWN = 0; 36 /** Port is on front left side of vehicle. */ 37 @AddedInOrBefore(majorVersion = 33) 38 public static final int FRONT_LEFT = 1; 39 /** Port is on front right side of vehicle. */ 40 @AddedInOrBefore(majorVersion = 33) 41 public static final int FRONT_RIGHT = 2; 42 /** Port is on rear right side of vehicle. */ 43 @AddedInOrBefore(majorVersion = 33) 44 public static final int REAR_RIGHT = 3; 45 /** Port is on rear left side of vehicle. */ 46 @AddedInOrBefore(majorVersion = 33) 47 public static final int REAR_LEFT = 4; 48 /** Port is on front of vehicle. */ 49 @AddedInOrBefore(majorVersion = 33) 50 public static final int FRONT = 5; 51 /** Port is on rear of vehicle. */ 52 @AddedInOrBefore(majorVersion = 33) 53 public static final int REAR = 6; 54 55 /** @hide */ 56 @IntDef({ 57 UNKNOWN, 58 FRONT_LEFT, 59 FRONT_RIGHT, 60 REAR_LEFT, 61 REAR_RIGHT, 62 FRONT, 63 REAR 64 }) 65 @Retention(RetentionPolicy.SOURCE) 66 67 public @interface Enum {} PortLocationType()68 private PortLocationType() {} 69 } 70