encode<V> static method
V
encode<
V>( - Request instance,
- Encoder<V> encoder
)
Implementation
static V encode<V>(
Request instance,
Encoder<V> encoder,
) {
final container = encoder.container<String>();
if (instance.body != null) {
container.encodeString(
'body',
instance.body!,
);
}
if (instance.headers != null) {
container.encodeList(
'headers',
(container) =>
instance.headers!.forEach((el) => InvoiceSettingCustomField.encode(
el,
container.nestedSingleValueContainer().encoder,
)),
);
}
return container.value;
}