ParkingPrice

public struct ParkingPrice

Calculated parking price when startTime and duaration are specified.

Important

This is a Public Preview API. It may be changed or removed at any time.

Lifecycle

  • Creates a new ParkingPrice

    Declaration

    Swift

    public init(start: Date, duration: Measurement<UnitDuration>, amount: Decimal, currency: String)

    Parameters

    start

    Starting time used for price calculation.

    duration

    Parking duration used for price calculation.

    amount

    Calculated parking price.

    currency

    Parking price currency.

Public

  • Starting time used for price calculation.

    Declaration

    Swift

    public let start: Date
  • Parking duration used for price calculation.

    Declaration

    Swift

    public let duration: Measurement<UnitDuration>
  • Calculated parking price.

    Declaration

    Swift

    public let amount: Decimal
  • Parking price currency.

    Declaration

    Swift

    public let currency: String