ChargingConnector

public struct ChargingConnector : Equatable, Hashable

Describes connector information of an electric engine.

  • Creates instance of ChargingConnector.

    Throws

    VehicleError.invalidVehicleSnapshot if the maximum current is less than zero.

    Throws

    VehicleError.invalidVehicleSnapshot if minimum voltage is less than zero.

    Throws

    VehicleError.invalidVehicleSnapshotif minimum voltage greater than or equal maximum voltage.

    Declaration

    Swift

    public init(
        currentType: CurrentType,
        plugTypes: Set<ConnectorType>,
        efficiency: Measurement<TTUnitRatio> = Measurement.tt.unitRange(1.0),
        baseLoad: Measurement<UnitPower> = Measurement.tt.kilowatts(0),
        maxPower: Measurement<UnitPower> = Measurement.tt.kilowatts(0),
        maxCurrent: Measurement<UnitElectricCurrent> = Measurement.tt.amperes(0),
        maxVoltage: Measurement<UnitElectricPotentialDifference> = Measurement.tt.volts(0),
        voltageRange: VoltageRange = .init(
            minVoltage: .tt.volts(0),
            maxVoltage: .tt.volts(0)
        )
    ) throws

    Parameters

    currentType

    Specifies the type of current used by vehicle for charging.

    plugTypes

    Specifies the available connector plug types.

    efficiency

    Specifies the charger’s efficiency. If not specified the default value 1.0 applies. Must be greater than zero and less than or equal to one.

    baseLoad

    Specifies the charger’s baseload. If not specified the default value 0.0 applies.

    maxPower

    Specifies the charger’s maximum power. If not specified the power is only limited by the charging facility. The maximum power must be a positive number or zero, where 0 implies no boundary applies.

    maxCurrent

    The maximum amperage of the charging connector. If not specified the amperage is only limited by the charging facility. Must be a positive number or zero, where zero implies no boundary applies.

    maxVoltage

    The maximum voltage of the charging connector. If not specified the voltage is only limited by the charging facility. Must be a positive number or zero, where zero implies no boundary applies.

    voltageRange

    Specifies minimal(included) and maximal(excluded) voltage values. The lower bound value should be a positive number or zero. The upper bound value should be greater than the lower bound or zero and is treated as infinity. If not specified a range of [0, infinity] is implied.

  • Specifies the type of current used by vehicle for charging.

    Declaration

    Swift

    public let currentType: CurrentType
  • Specifies the available connector plug types.

    Declaration

    Swift

    public let plugTypes: Set<ConnectorType>
  • Specifies the charger efficiency. If not specified the default value 1.0 applies. Must be greater than zero and less than or equal to one.

    Declaration

    Swift

    public let efficiency: Measurement<TTUnitRatio>
  • Specifies the charger baseload. If not specified the default value 0.0 applies.

    Declaration

    Swift

    public let baseLoad: Measurement<UnitPower>
  • Specifies the charger’s maximum power. If not specified the power is only limited by the charging facility. The maximum power must be a positive number or zero, where 0 implies no boundary applies.

    Declaration

    Swift

    public let maxPower: Measurement<UnitPower>
  • The maximum voltage of the charging connector. If not specified the voltage is only limited by the charging facility. Must be a positive number or zero, where 0 implies no boundary applies.

    Declaration

    Swift

    public let maxVoltage: Measurement<UnitElectricPotentialDifference>
  • The maximum amperage of the charging connector. If not specified the amperage is only limited by the charging facility. Must be a positive number or zero, where 0 implies no boundary applies.

    Declaration

    Swift

    public let maxCurrent: Measurement<UnitElectricCurrent>
  • Specifies minimal(included) and maximal(excluded) voltage values. The lower bound value should be a positive number or zero. The upper bound value should be greater than the lower bound or zero and is treated as infinity. If not specified a range of [0, infinity] is implied.

    Declaration

    Swift

    public let voltageRange: VoltageRange