exportSnapshot

@RequiresApi(value = 29)
suspend fun AppWidgetHostView.exportSnapshot(fileName: String? = null): Result<Uri>

Extracts and image from the current host and stores it in the device picture directory

Return

the result of the operation with the image URI if successful

Parameters

fileName

optional filename (without extension), otherwise the app name + date will be used.