SearchVideo.fromJson constructor
SearchVideo.fromJson Mapping data to SearchVideo
Implementation
factory SearchVideo.fromJson(Map<String, dynamic> json) {
/// [SearchVideo] Mapping object
return SearchVideo(
page: json['page'] as int?,
perPage: json['per_page'] as int?,
totalResults: json['total_results'] as int?,
nextPage: json['next_page'] as String?,
prevPage: json['prev_page'] as String?,
url: json['url'] as String?,
videos: _videoList(json['videos'] as List<dynamic>?));
}