# Operation.State.FAILURE

Artifact: [androidx.work:work-runtime](https://developer.android.com/jetpack/androidx/releases/work) [View Source](https://cs.android.com/search?q=file:androidx/work/Operation.java+class:androidx.work.Operation.State.FAILURE) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/work#1.0.0)

*** ** * ** ***


```
public final class Operation.State.FAILURE extends Operation.State
```

<br />

|---|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object.html) |||
| ↳ | [androidx.work.Operation.State](https://developer.android.com/reference/androidx/work/Operation.State) ||
|   | ↳ | [androidx.work.Operation.State.FAILURE](https://developer.android.com/reference/androidx/work/Operation.State.FAILURE) |

*** ** * ** ***

This represents an `https://developer.android.com/reference/androidx/work/Operation` which has failed.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/work/Operation.State.FAILURE#FAILURE(java.lang.Throwable)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/Throwable.html exception)` |

| ### Public methods |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/Throwable.html` | `https://developer.android.com/reference/androidx/work/Operation.State.FAILURE#getThrowable()()` |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/work/Operation.State.FAILURE#toString()()` |

## Public constructors

### FAILURE

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

```
public FAILURE(@NonNull Throwable exception)
```

## Public methods

### getThrowable

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

```
public @NonNull Throwable getThrowable()
```

| Returns |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/Throwable.html` | The `https://developer.android.com/reference/java/lang/Throwable.html` which caused the `https://developer.android.com/reference/androidx/work/Operation` to fail. |

### toString

```
public @NonNull String toString()
```