PrefetchOperationCallback


@Profile.ExperimentalUrlPrefetch
interface PrefetchOperationCallback<T>


Callback interface for prefetch operations.

Parameters
<T>

The type of the result returned on successful operation.

Summary

Public functions

Unit
onError(exception: Throwable?)

Called when the prefetch operation fails.

Unit
onSuccess(result: T!)

Called when the prefetch operation completes successfully.

Public functions

onError

fun onError(exception: Throwable?): Unit

Called when the prefetch operation fails.

Parameters
exception: Throwable?

The exception indicating the cause of the failure.

onSuccess

fun onSuccess(result: T!): Unit

Called when the prefetch operation completes successfully.

Parameters
result: T!

The result of the prefetch operation.