ocpp/v2_1/datatype/gradient_get
OCPP 2.1 GradientGet data type (schema GradientGetType).
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 |
|---|---|---|---|
custom_data | CustomData | — | |
gradient | Gradient | ✓ | |
id | String | ✓ | Id of setting (max 36 chars) |
Schema: GradientGetType
pub type GradientGet {
GradientGet(
custom_data: option.Option(custom_data.CustomData),
gradient: gradient.Gradient,
id: String,
)
}
Constructors
-
GradientGet( custom_data: option.Option(custom_data.CustomData), gradient: gradient.Gradient, id: String, )
Values
pub fn decoder() -> decode.Decoder(GradientGet)
Decode a GradientGet from its OCPP-J JSON object, enforcing schema constraints.
pub fn new(
gradient gradient: gradient.Gradient,
id id: String,
) -> GradientGet
Construct a GradientGet from its required fields, with every optional field set to None.
pub fn to_json(value: GradientGet) -> json.Json
Encode a GradientGet to its OCPP-J JSON object.