PatchbayRejectionWire.fromJson constructor

PatchbayRejectionWire.fromJson(
  1. Map<String, Object?> json, {
  2. String path = r'$',
})

Decodes a strict JSON object at path.

Implementation

factory PatchbayRejectionWire.fromJson(
  Map<String, Object?> json, {
  String path = r'$',
}) {
  _wireKeys(json, const <String>{'code', 'notice', 'details'}, path);
  return PatchbayRejectionWire(
    code: _wireString(json['code'], '$path.code'),
    notice: json['notice'] == null
        ? null
        : _wireString(json['notice'], '$path.notice'),
    details: json['details'] == null
        ? const <String, Object?>{}
        : _wireJsonObject(json['details'], '$path.details'),
  );
}