# SandboxedUiAdapter.SessionClient

Artifact: [androidx.privacysandbox.ui:ui-core](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui) [View Source](https://cs.android.com/search?q=file:androidx/privacysandbox/ui/core/SandboxedUiAdapter.kt+class:androidx.privacysandbox.ui.core.SandboxedUiAdapter.SessionClient) Added in [1.0.0-alpha17](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui#1.0.0-alpha17) Deprecated in [1.0.0-alpha17](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui#1.0.0-alpha17)

*** ** * ** ***


```
public interface SandboxedUiAdapter.SessionClient
```

<br />

*** ** * ** ***

> [!CAUTION]
> **This interface is deprecated.**   
> This library is no longer supported.

The client of a single session that will receive callback events from an active session.

## Summary

| ### Public methods |
|---|---|
| `abstract void` | `[onResizeRequested](https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient#onResizeRequested(kotlin.Int,kotlin.Int))(int width, int height)` **This method is deprecated.** This library is no longer supported. |
| `abstract void` | `[onSessionError](https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient#onSessionError(kotlin.Throwable))(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Throwable.html throwable)` **This method is deprecated.** This library is no longer supported. |
| `abstract void` | `[onSessionOpened](https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient#onSessionOpened(androidx.privacysandbox.ui.core.SandboxedUiAdapter.Session))(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.Session session)` **This method is deprecated.** This library is no longer supported. |

## Public methods

### onResizeRequested

Added in [1.0.0-alpha17](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui#1.0.0-alpha17) Deprecated in [1.0.0-alpha17](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui#1.0.0-alpha17)

```
abstract void [onResizeRequested](https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient#onResizeRequested(kotlin.Int,kotlin.Int))(int width, int height)
```

> [!CAUTION]
> **This method is deprecated.**   
> This library is no longer supported.

Called when the provider of content would like the UI to be presented at `https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient#onResizeRequested(kotlin.Int,kotlin.Int)` and `https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient#onResizeRequested(kotlin.Int,kotlin.Int)`. The library tries to get as close a fit as possible whilst staying within the container's constraints.

### onSessionError

Added in [1.0.0-alpha17](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui#1.0.0-alpha17) Deprecated in [1.0.0-alpha17](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui#1.0.0-alpha17)

```
abstract void [onSessionError](https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient#onSessionError(kotlin.Throwable))(@NonNull Throwable throwable)
```

> [!CAUTION]
> **This method is deprecated.**   
> This library is no longer supported.

Called to report a terminal error in the session. No further events will be reported to this `https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient` and any further or currently pending calls to the `https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.Session` that may have been in flight may be ignored.

### onSessionOpened

Added in [1.0.0-alpha17](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui#1.0.0-alpha17) Deprecated in [1.0.0-alpha17](https://developer.android.com/jetpack/androidx/releases/privacysandbox-ui#1.0.0-alpha17)

```
abstract void [onSessionOpened](https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.SessionClient#onSessionOpened(androidx.privacysandbox.ui.core.SandboxedUiAdapter.Session))(@NonNull SandboxedUiAdapter.Session session)
```

> [!CAUTION]
> **This method is deprecated.**   
> This library is no longer supported.

Called to report that the session was opened successfully, delivering the `https://developer.android.com/reference/androidx/privacysandbox/ui/core/SandboxedUiAdapter.Session` handle that should be used to notify the session of UI events.