Add property for multiple ev port locations

Some cars have multiple ev ports.

Bug: 117599455
Test: google VHAL and kitchenSink app
Change-Id: Iccccac9b3de3c63bf847285dcabbd29eb7b4367a
diff --git a/car-lib/api/current.txt b/car-lib/api/current.txt
index 73cb9db..a6e19f7 100644
--- a/car-lib/api/current.txt
+++ b/car-lib/api/current.txt
@@ -293,6 +293,7 @@
     field @RequiresPermission(android.car.Car.PERMISSION_CAR_INFO) public static final int INFO_MAKE = 286261505; // 0x11100101
     field @RequiresPermission(android.car.Car.PERMISSION_CAR_INFO) public static final int INFO_MODEL = 286261506; // 0x11100102
     field @RequiresPermission(android.car.Car.PERMISSION_CAR_INFO) public static final int INFO_MODEL_YEAR = 289407235; // 0x11400103
+    field @RequiresPermission(android.car.Car.PERMISSION_CAR_INFO) public static final int INFO_MULTI_EV_PORT_LOCATIONS = 289472780; // 0x1141010c
     field @RequiresPermission(android.car.Car.PERMISSION_IDENTIFICATION) public static final int INFO_VIN = 286261504; // 0x11100100
     field public static final int INITIAL_USER_INFO = 299896583; // 0x11e00f07
     field public static final int INVALID = 0; // 0x0
diff --git a/car-lib/src/android/car/VehiclePropertyIds.java b/car-lib/src/android/car/VehiclePropertyIds.java
index f6959fe..60b3b0a 100644
--- a/car-lib/src/android/car/VehiclePropertyIds.java
+++ b/car-lib/src/android/car/VehiclePropertyIds.java
@@ -72,24 +72,50 @@
     @RequiresPermission(Car.PERMISSION_CAR_INFO)
     public static final int INFO_EV_BATTERY_CAPACITY = 291504390;
     /**
-     * List of connectors this EV may use
+     * List of connectors this vehicle may use
+     *
+     * <p>Applications can query the property value by
+     * {@link android.car.hardware.property.CarPropertyManager#getIntArrayProperty(int, int)}. The
+     * return value is an integer array containing enums in {@link EvConnectorType}
+     *
      * Requires permission: {@link Car#PERMISSION_CAR_INFO}.
      */
     @RequiresPermission(Car.PERMISSION_CAR_INFO)
     public static final int INFO_EV_CONNECTOR_TYPE = 289472775;
     /**
      * Fuel door location
+     *
+     * <p> Applications can query the property value by
+     * {@link android.car.hardware.property.CarPropertyManager#getIntProperty(int, int)}. The return
+     * value is one of enums in {@link PortLocationType}.
+     *
      * Requires permission: {@link Car#PERMISSION_CAR_INFO}.
      */
     @RequiresPermission(Car.PERMISSION_CAR_INFO)
     public static final int INFO_FUEL_DOOR_LOCATION = 289407240;
     /**
      * EV port location
+     *
+     * <p> Applications can query the property value by
+     * {@link android.car.hardware.property.CarPropertyManager#getIntProperty(int, int)}. The return
+     * value is one of enums in {@link PortLocationType}.
+     *
      * Requires permission: {@link Car#PERMISSION_CAR_INFO}.
      */
     @RequiresPermission(Car.PERMISSION_CAR_INFO)
     public static final int INFO_EV_PORT_LOCATION = 289407241;
     /**
+     * Multiple EV port locations
+     *
+     * <p> Applications can query the property value by
+     * {@link android.car.hardware.property.CarPropertyManager#getIntArrayProperty(int, int)}. The
+     * return value is an integer array containing enums in {@link PortLocationType}.
+     *
+     * Requires permission: {@link Car#PERMISSION_CAR_INFO}.
+     */
+    @RequiresPermission(Car.PERMISSION_CAR_INFO)
+    public static final int INFO_MULTI_EV_PORT_LOCATIONS = 289472780;
+    /**
      * Driver's seat location
      * Requires permission: {@link Car#PERMISSION_CAR_INFO}.
      */
@@ -928,6 +954,8 @@
                 return "INFO_FUEL_TYPE";
             case INFO_EV_BATTERY_CAPACITY:
                 return "INFO_EV_BATTERY_CAPACITY";
+            case INFO_MULTI_EV_PORT_LOCATIONS:
+                return "INFO_MULTI_EV_PORT_LOCATIONS";
             case INFO_EV_CONNECTOR_TYPE:
                 return "INFO_EV_CONNECTOR_TYPE";
             case INFO_FUEL_DOOR_LOCATION:
diff --git a/service/src/com/android/car/hal/PropertyHalServiceIds.java b/service/src/com/android/car/hal/PropertyHalServiceIds.java
index 2f7ae61..b9f3134 100644
--- a/service/src/com/android/car/hal/PropertyHalServiceIds.java
+++ b/service/src/com/android/car/hal/PropertyHalServiceIds.java
@@ -319,6 +319,9 @@
         mProps.put(VehicleProperty.INFO_FUEL_DOOR_LOCATION, new Pair<>(
                     Car.PERMISSION_CAR_INFO,
                     null));
+        mProps.put(VehicleProperty.INFO_MULTI_EV_PORT_LOCATIONS, new Pair<>(
+                    Car.PERMISSION_CAR_INFO,
+                    null));
         mProps.put(VehicleProperty.INFO_EV_PORT_LOCATION, new Pair<>(
                     Car.PERMISSION_CAR_INFO,
                     null));