fetchMediaComposition
Fetches a MediaComposition located at the provided uri.
val mediaCompositionResult = mediaCompositionService.fetchMediaComposition(uri)
val mediaComposition = mediaCompositionResult.getOrNull()
if (mediaComposition == null) {
val throwable = mediaCompositionResult.exceptionOrNull()
// Handle error
} else {
// Do something with the media composition
}
Content copied to clipboard
Return
A Result containing either the successfully fetched MediaComposition or an error indicating the reason for failure.
Parameters
uri
The URI identifying the desired MediaComposition.