CmafPackage.fromJson constructor
CmafPackage.fromJson(
- Map<String, dynamic> json
)
Implementation
factory CmafPackage.fromJson(Map<String, dynamic> json) {
return CmafPackage(
encryption: json['encryption'] != null
? CmafEncryption.fromJson(json['encryption'] as Map<String, dynamic>)
: null,
hlsManifests: (json['hlsManifests'] as List?)
?.whereNotNull()
.map((e) => HlsManifest.fromJson(e as Map<String, dynamic>))
.toList(),
segmentDurationSeconds: json['segmentDurationSeconds'] as int?,
segmentPrefix: json['segmentPrefix'] as String?,
streamSelection: json['streamSelection'] != null
? StreamSelection.fromJson(
json['streamSelection'] as Map<String, dynamic>)
: null,
);
}