MediaItem.fromJson constructor

MediaItem.fromJson(
  1. Map json_
)

Implementation

MediaItem.fromJson(core.Map json_)
    : this(
        baseUrl: json_.containsKey('baseUrl')
            ? json_['baseUrl'] as core.String
            : null,
        contributorInfo: json_.containsKey('contributorInfo')
            ? ContributorInfo.fromJson(json_['contributorInfo']
                as core.Map<core.String, core.dynamic>)
            : null,
        description: json_.containsKey('description')
            ? json_['description'] as core.String
            : null,
        filename: json_.containsKey('filename')
            ? json_['filename'] as core.String
            : null,
        id: json_.containsKey('id') ? json_['id'] as core.String : null,
        mediaMetadata: json_.containsKey('mediaMetadata')
            ? MediaMetadata.fromJson(
                json_['mediaMetadata'] as core.Map<core.String, core.dynamic>)
            : null,
        mimeType: json_.containsKey('mimeType')
            ? json_['mimeType'] as core.String
            : null,
        productUrl: json_.containsKey('productUrl')
            ? json_['productUrl'] as core.String
            : null,
      );