# ExtendableSavedState

[View Source](https://github.com/material-components/material-components-android/blob/1.14.0/lib/java/com/google/android/material/stateful/ExtendableSavedState.java)

*** ** * ** ***


```
public class ExtendableSavedState
```

<br />

*** ** * ** ***

SavedState for widgets that want to save and restore their own state in onSaveInstanceState. Supports widgets whose state is composed or delegated out to multiple components.

Widgets with only composed or delegated state can directly instantiate this class and write to `https://developer.android.com/reference/com/google/android/material/stateful/ExtendableSavedState#extendableStates()`. Widgets with additional state should subclass ExtendableSavedState rather than trying to force the additional state into `https://developer.android.com/reference/com/google/android/material/stateful/ExtendableSavedState#extendableStates()`.

## Summary

| ### Constants |
|---|---|
| `static final Creator<ExtendableSavedState>` | `https://developer.android.com/reference/com/google/android/material/stateful/ExtendableSavedState#CREATOR()` |

| ### Public fields |
|---|---|
| `final SimpleArrayMap<String, Bundle>` | `https://developer.android.com/reference/com/google/android/material/stateful/ExtendableSavedState#extendableStates()` |

| ### Public constructors |
|---|
| `https://developer.android.com/reference/com/google/android/material/stateful/ExtendableSavedState#ExtendableSavedState(Parcelable)(Parcelable superState)` |

| ### Public methods |
|---|---|
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/com/google/android/material/stateful/ExtendableSavedState#toString()()` |
| `void` | `https://developer.android.com/reference/com/google/android/material/stateful/ExtendableSavedState#writeToParcel(Parcel,int)(Parcel out, int flags)` |

## Constants

### CREATOR

```
public static final Creator<ExtendableSavedState> CREATOR
```

## Public fields

### extendableStates

```
public final SimpleArrayMap<String, Bundle> extendableStates
```

## Public constructors

### ExtendableSavedState

```
public ExtendableSavedState(Parcelable superState)
```

## Public methods

### toString

```
public String toString()
```

### writeToParcel

```
public void writeToParcel(Parcel out, int flags)
```