ocpp/v1_6/datatype/charging_schedule
OCPP 1.6 ChargingSchedule data type.
to_json/decoder map to/from its OCPP-J JSON object; new (when
present) builds a value from the required fields only.
Types
| Field | Type | Req | Description |
|---|---|---|---|
charging_rate_unit | ChargingRateUnitType | ✓ | |
charging_schedule_period | List(ChargingSchedulePeriod) | ✓ | |
duration | Int | — | |
min_charging_rate | Float | — | |
start_schedule | DateTime | — |
Schema: ChargingSchedule
pub type ChargingSchedule {
ChargingSchedule(
charging_rate_unit: charging_rate_unit_type.ChargingRateUnitType,
charging_schedule_period: List(
charging_schedule_period.ChargingSchedulePeriod,
),
duration: option.Option(Int),
min_charging_rate: option.Option(Float),
start_schedule: option.Option(timestamp.Timestamp),
)
}
Constructors
-
ChargingSchedule( charging_rate_unit: charging_rate_unit_type.ChargingRateUnitType, charging_schedule_period: List( charging_schedule_period.ChargingSchedulePeriod, ), duration: option.Option(Int), min_charging_rate: option.Option(Float), start_schedule: option.Option(timestamp.Timestamp), )
Values
pub fn decoder() -> decode.Decoder(ChargingSchedule)
Decode a ChargingSchedule from its OCPP-J JSON object, enforcing schema constraints.
pub fn new(
charging_rate_unit charging_rate_unit: charging_rate_unit_type.ChargingRateUnitType,
charging_schedule_period charging_schedule_period: List(
charging_schedule_period.ChargingSchedulePeriod,
),
) -> ChargingSchedule
Construct a ChargingSchedule from its required fields, with every optional field set to None.
pub fn to_json(value: ChargingSchedule) -> json.Json
Encode a ChargingSchedule to its OCPP-J JSON object.