EnergyProfile.Builder

public static final class EnergyProfile.Builder
extends Object

java.lang.Object
   ↳ androidx.car.app.hardware.info.EnergyProfile.Builder


A builder of EnergyProfile.

Summary

Public constructors

Builder()

Public methods

EnergyProfile build()

Constructs the EnergyProfile defined by this builder.

EnergyProfile.Builder setEvConnectorTypes(CarValue<List<Integer>> evConnectorTypes)

Sets the cars EV connector types.

EnergyProfile.Builder setFuelTypes(CarValue<List<Integer>> fuelTypes)

Sets the cars fuel types.

Inherited methods

Public constructors

Builder

public Builder ()

Public methods

build

public EnergyProfile build ()

Constructs the EnergyProfile defined by this builder.

Any fields which have not been set are added with null value and CarValue.STATUS_UNIMPLEMENTED.

Returns
EnergyProfile

setEvConnectorTypes

public EnergyProfile.Builder setEvConnectorTypes (CarValue<List<Integer>> evConnectorTypes)

Sets the cars EV connector types.

Parameters
evConnectorTypes CarValue

Returns
EnergyProfile.Builder

Throws
NullPointerException if evConnectorTypes is null

setFuelTypes

public EnergyProfile.Builder setFuelTypes (CarValue<List<Integer>> fuelTypes)

Sets the cars fuel types.

Parameters
fuelTypes CarValue

Returns
EnergyProfile.Builder

Throws
NullPointerException if fuelTypes is null