# CronetException


```
abstract class CronetException : IOException
```

<br />

|---|---|---|---|---|
| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html) |||||
| ↳ | [kotlin.Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html) ||||
|   | ↳ | [java.lang.Exception](https://developer.android.com/reference/java/lang/Exception.html) |||
|   |   | ↳ | [java.io.IOException](https://developer.android.com/reference/java/io/IOException.html) ||
|   |   |   | ↳ | [org.chromium.net.CronetException](https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/CronetException) |

Known direct subclasses [CallbackException](https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/CallbackException), [NetworkException](https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/NetworkException)

|---|---|
| `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/CallbackException` | Exception passed to `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/UrlRequest.Callback#onFailed(org.chromium.net.UrlRequest,org.chromium.net.UrlResponseInfo,org.chromium.net.CronetException)` when `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/UrlRequest.Callback` or `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/UploadDataProvider` method throws an exception. |
| `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/NetworkException` | Exception passed to `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/UrlRequest.Callback#onFailed(org.chromium.net.UrlRequest,org.chromium.net.UrlResponseInfo,org.chromium.net.CronetException)` when Cronet fails to process a network request. |

Known indirect subclasses [QuicException](https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/QuicException)

|---|---|
| `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/QuicException` | Subclass of `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/NetworkException` which contains a detailed [QUIC](https://www.chromium.org/quic) error code from [QuicErrorCode](https://cs.chromium.org/search/?q=symbol:%5CbQuicErrorCode%5Cb). |

*** ** * ** ***

Base exception passed to `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/UrlRequest.Callback#onFailed(org.chromium.net.UrlRequest,org.chromium.net.UrlResponseInfo,org.chromium.net.CronetException)`.

## Summary

| ### Protected constructors |
|---|
| `https://developer.android.com/develop/connectivity/cronet/reference/kotlin/org/chromium/net/CronetException#CronetException(java.lang.String,java.lang.Throwable)(message: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html!, cause: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html!)` Constructs an exception that is caused by `cause`. |

| ### Inherited functions |
|---|
| From [java.lang.Throwable](https://developer.android.com/reference/java/lang/Throwable.html) |---|---| | `synchronized https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/add-suppressed.html(p: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html!)` | | `synchronized https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html!` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/fill-in-stack-trace.html()` | | `synchronized https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html!` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/get-cause.html()` | | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html!` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/get-localized-message.html()` | | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html!` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/get-message.html()` | | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-array/index.html<https://developer.android.com/reference/java/lang/StackTraceElement.html!>!` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/get-stack-trace.html()` | | `synchronized https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html!>!` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/get-suppressed.html()` | | `synchronized https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html!` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/init-cause.html(p: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html!)` | | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/print-stack-trace.html()` | | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/set-stack-trace.html(p: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-array/index.html<https://developer.android.com/reference/java/lang/StackTraceElement.html!>!)` | | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html!` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/to-string.html()` | |

## Protected constructors

### CronetException

```
protected CronetException(message: String!, cause: Throwable!)
```

Constructs an exception that is caused by `cause`.

| Parameters |
|---|---|
| `message: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html!` | explanation of failure. |
| `cause: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html!` | the cause (which is saved for later retrieval by the `https://developer.android.com/reference/java/lang/Throwable.html#getCause()` method). A null value is permitted, and indicates that the cause is nonexistent or unknown. |