Input$PredefinedInput.fromJson constructor

Input$PredefinedInput.fromJson(
  1. Map<String, dynamic> data
)

Implementation

factory Input$PredefinedInput.fromJson(Map<String, dynamic> data) {
  final result$data = <String, dynamic>{};
  if (data.containsKey('title')) {
    final l$title = data['title'];
    result$data['title'] = (l$title as String?);
  }
  if (data.containsKey('code')) {
    final l$code = data['code'];
    result$data['code'] = (l$code as String?);
  }
  if (data.containsKey('description')) {
    final l$description = data['description'];
    result$data['description'] = (l$description as String?);
  }
  if (data.containsKey('icon')) {
    final l$icon = data['icon'];
    result$data['icon'] = (l$icon as String?);
  }
  if (data.containsKey('media')) {
    final l$media = data['media'];
    result$data['media'] = l$media == null
        ? null
        : Input$MediaInput.fromJson((l$media as Map<String, dynamic>));
  }
  return Input$PredefinedInput._(result$data);
}