toJson method
Implementation
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = <String, dynamic>{};
data['type'] = type;
if (widgetSettings != null) {
data['widget_settings'] = widgetSettings!.toJson();
}
if (response != null) {
data['response'] = response!.toJson();
}
if (contentIndex != null) data['content_index'] = contentIndex;
if (delta != null) data['delta'] = delta;
if (itemId != null) data['item_id'] = itemId;
if (outputIndex != null) data['output_index'] = outputIndex;
if (responseId != null) data['response_id'] = responseId;
if (item != null) data['item'] = item!.toJson();
if (previousItemId != null) data['previous_item_id'] = previousItemId;
return data;
}