Package org.opencabstandard.provider
Class VehicleInformationContract.VehicleInformation
java.lang.Object
org.opencabstandard.provider.VehicleInformationContract.VehicleInformation
- All Implemented Interfaces:
android.os.Parcelable
- Enclosing class:
- VehicleInformationContract
public static class VehicleInformationContract.VehicleInformation
extends Object
implements android.os.Parcelable
Object containing the vehicle information.
-
Nested Class Summary
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final android.os.Parcelable.Creator<VehicleInformationContract.VehicleInformation>Fields inherited from interface android.os.Parcelable
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintA string to identify the vehicle id.getVin()A string to identify the vehicle vin number.booleanisInGear()Is the vehicle currently in gear? True = vehicle is in gear False = vehicle is in park or neutralvoidsetInGear(boolean status) Indicate whether the vehicle is in gear.voidsetVehicleId(String id) A string to identify the vehicle id.voidA string to identify the vehicle vin number.voidwriteToParcel(android.os.Parcel dest, int flags)
-
Field Details
-
CREATOR
public static final android.os.Parcelable.Creator<VehicleInformationContract.VehicleInformation> CREATOR
-
-
Constructor Details
-
VehicleInformation
public VehicleInformation() -
VehicleInformation
protected VehicleInformation(android.os.Parcel in)
-
-
Method Details
-
setVin
A string to identify the vehicle vin number.- Parameters:
vin- The vehicle information number (VIN) as a string, e.g. "1M2AX07Y79M006004"
-
getVin
A string to identify the vehicle vin number.- Returns:
- vin The vehicle information number (VIN) as a string, e.g. "1M2AX07Y79M006004"
-
setVehicleId
A string to identify the vehicle id.- Parameters:
id- The vehicle identifier.
-
getVehicleId
A string to identify the vehicle id.- Returns:
- vehicleId The vehicle id.
-
isInGear
public boolean isInGear()Is the vehicle currently in gear? True = vehicle is in gear False = vehicle is in park or neutral- Returns:
- Boolean indicating whether the vehicle is currently in gear.
-
setInGear
public void setInGear(boolean status) Indicate whether the vehicle is in gear. If false, the vehicle is not and does not intend on moving.- Parameters:
status- Boolean indicating if the vehicle is currently in gear.
-
writeToParcel
public void writeToParcel(android.os.Parcel dest, int flags) - Specified by:
writeToParcelin interfaceandroid.os.Parcelable
-
describeContents
public int describeContents()- Specified by:
describeContentsin interfaceandroid.os.Parcelable
-