[android-components](../index.md) / [mozilla.components.browser.session.ext](./index.md)

## Package mozilla.components.browser.session.ext

### Functions

| Name | Summary |
|---|---|
| [readSnapshot](read-snapshot.md) | `fun <ERROR CLASS>.readSnapshot(engine: `[`Engine`](../mozilla.components.concept.engine/-engine/index.md)`, serializer: `[`SnapshotSerializer`](../mozilla.components.browser.session.storage/-snapshot-serializer/index.md)` = SnapshotSerializer()): `[`Snapshot`](../mozilla.components.browser.session/-session-manager/-snapshot/index.md)`?`<br>Read a [SessionManager.Snapshot](../mozilla.components.browser.session/-session-manager/-snapshot/index.md) from this [AtomicFile](#). Returns `null` if no snapshot could be read. |
| [readSnapshotItem](read-snapshot-item.md) | `fun <ERROR CLASS>.readSnapshotItem(engine: `[`Engine`](../mozilla.components.concept.engine/-engine/index.md)`, restoreSessionId: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)`, serializer: `[`SnapshotSerializer`](../mozilla.components.browser.session.storage/-snapshot-serializer/index.md)` = SnapshotSerializer(restoreSessionId)): `[`Item`](../mozilla.components.browser.session/-session-manager/-snapshot/-item/index.md)`?`<br>Reads a single [SessionManager.Snapshot.Item](../mozilla.components.browser.session/-session-manager/-snapshot/-item/index.md) from this [AtomicFile](#). Returns `null` if no snapshot item could be read. |
| [toCustomTabSessionState](to-custom-tab-session-state.md) | `fun `[`Session`](../mozilla.components.browser.session/-session/index.md)`.toCustomTabSessionState(): `[`CustomTabSessionState`](../mozilla.components.browser.state.state/-custom-tab-session-state/index.md)<br>Creates a matching [CustomTabSessionState](../mozilla.components.browser.state.state/-custom-tab-session-state/index.md) from a [Session](../mozilla.components.browser.session/-session/index.md) |
| [toSecurityInfoState](to-security-info-state.md) | `fun `[`SecurityInfo`](../mozilla.components.browser.session/-session/-security-info/index.md)`.toSecurityInfoState(): `[`SecurityInfoState`](../mozilla.components.browser.state.state/-security-info-state/index.md)<br>Creates a matching [SecurityInfoState](../mozilla.components.browser.state.state/-security-info-state/index.md) from a [Session.SecurityInfo](../mozilla.components.browser.session/-session/-security-info/index.md) |
| [toTabSessionState](to-tab-session-state.md) | `fun `[`Session`](../mozilla.components.browser.session/-session/index.md)`.toTabSessionState(): `[`TabSessionState`](../mozilla.components.browser.state.state/-tab-session-state/index.md)<br>Create a matching [TabSessionState](../mozilla.components.browser.state.state/-tab-session-state/index.md) from a [Session](../mozilla.components.browser.session/-session/index.md). |
| [writeSnapshot](write-snapshot.md) | `fun <ERROR CLASS>.writeSnapshot(snapshot: `[`Snapshot`](../mozilla.components.browser.session/-session-manager/-snapshot/index.md)`, serializer: `[`SnapshotSerializer`](../mozilla.components.browser.session.storage/-snapshot-serializer/index.md)` = SnapshotSerializer()): `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)<br>Saves the given [SessionManager.Snapshot](../mozilla.components.browser.session/-session-manager/-snapshot/index.md) to this [AtomicFile](#). |
| [writeSnapshotItem](write-snapshot-item.md) | `fun <ERROR CLASS>.writeSnapshotItem(item: `[`Item`](../mozilla.components.browser.session/-session-manager/-snapshot/-item/index.md)`, serializer: `[`SnapshotSerializer`](../mozilla.components.browser.session.storage/-snapshot-serializer/index.md)` = SnapshotSerializer()): `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)<br>Saves a single [SessionManager.Snapshot.Item](../mozilla.components.browser.session/-session-manager/-snapshot/-item/index.md) to this [AtomicFile](#). |
