# PrefetchResult

Artifact: [androidx.webkit:webkit](https://developer.android.com/jetpack/androidx/releases/webkit) [View Source](https://cs.android.com/search?q=file:androidx/webkit/PrefetchResult.java+class:androidx.webkit.PrefetchResult) Added in [1.17.0](https://developer.android.com/jetpack/androidx/releases/webkit#1.17.0)

*** ** * ** ***


```
@Profile.ExperimentalUrlPrefetch
class PrefetchResult
```

<br />

*** ** * ** ***

Represents the outcome of a successful prefetch operation.

A `https://developer.android.com/reference/kotlin/androidx/webkit/PrefetchResult` is returned via `https://developer.android.com/reference/kotlin/androidx/webkit/PrefetchCache` prefetch operations when a prefetch request has been handled in a non-failing way.

## Summary

| ### Public functions |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/webkit/PrefetchResult#wasDuplicate()()` Returns whether the prefetch request was deduplicated against an existing entry in the prefetch cache. |

## Public functions

### wasDuplicate

Added in [1.17.0](https://developer.android.com/jetpack/androidx/releases/webkit#1.17.0)

```
fun wasDuplicate(): Boolean
```

Returns whether the prefetch request was deduplicated against an existing entry in the prefetch cache.

WebView performs deduplication when a prefetch request matches an existing in-flight or completed prefetch request. Matching is based on the URL and, if provided in `https://developer.android.com/reference/kotlin/androidx/webkit/PrefetchParameters`, the expected No-Vary-Search (NVS) data.

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `true` if the request was deduplicated, `false` otherwise. |