toJson method

  1. @override
Map<String, dynamic> toJson()
override

Re-encode to the externally-tagged wire shape ({tag: payload}).

Implementation

@override
Map<String, dynamic> toJson() => {
      'ResponseMetadata': {
        if (id != null) 'id': id,
        if (timestamp != null) 'timestamp': timestamp,
        if (modelId != null) 'model_id': modelId,
      },
    };