1 /*
2  * Copyright (C) 2021 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.hardware.property;
17 import android.annotation.IntDef;
18 
19 import java.lang.annotation.Retention;
20 import java.lang.annotation.RetentionPolicy;
21 
22 /**
23  * Used by {@link android.car.VehiclePropertyIds#ELECTRONIC_TOLL_COLLECTION_CARD_STATUS} to
24  * enumerate ETC(electronic toll collection) card types in the vehicle.
25  * Use in {@link android.car.hardware.property.CarPropertyManager#getProperty(int, int)} to
26  * get this property value.
27  */
28 public class VehicleElectronicTollCollectionCardStatus {
29     /**
30      * Status could not be determined
31      */
32     public static final int UNKNOWN = 0;
33     /**
34      * A valid electronic toll collection card is present
35      */
36     public static final int ELECTRONIC_TOLL_COLLECTION_CARD_VALID = 1;
37     /**
38      * An electronic toll collection card is present, but it is expired or otherwise invalid
39      */
40     public static final int ELECTRONIC_TOLL_COLLECTION_CARD_INVALID = 2;
41     /**
42      * No electronic toll collection card is inserted in the reader
43      */
44     public static final int ELECTRONIC_TOLL_COLLECTION_CARD_NOT_INSERTED = 3;
45 
46     /** @hide */
47     @IntDef({
48             UNKNOWN,
49             ELECTRONIC_TOLL_COLLECTION_CARD_VALID,
50             ELECTRONIC_TOLL_COLLECTION_CARD_NOT_INSERTED,
51             ELECTRONIC_TOLL_COLLECTION_CARD_INVALID
52     })
53     @Retention(RetentionPolicy.SOURCE)
54     public @interface Enum {}
VehicleElectronicTollCollectionCardStatus()55     private VehicleElectronicTollCollectionCardStatus() {}
56 }
57