# WindowLayoutInfo

Artifact: [androidx.window:window](https://developer.android.com/jetpack/androidx/releases/window) [View Source](https://cs.android.com/search?q=file:androidx/window/layout/WindowLayoutInfo.kt+class:androidx.window.layout.WindowLayoutInfo) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/window#1.0.0)

*** ** * ** ***

<br />

```
public final class WindowLayoutInfo
```

<br />

*** ** * ** ***

Contains the list of `https://developer.android.com/reference/androidx/window/layout/DisplayFeature`-s present in the window and the window's engagement mode.

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/window/layout/WindowInfoTracker#windowLayoutInfo(android.content.Context)` |   |
| `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode` |   |

## Summary

| ### Nested types |
|---|
| `public final class https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode` **This class is deprecated.** Use WindowEngagementInfo.EngagementMode instead |

| ### Public methods |
|---|---|
| `boolean` | `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#equals(kotlin.Any)(https://developer.android.com/reference/java/lang/Object.html other)` |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/util/List.html<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/window/layout/DisplayFeature>` | `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#getDisplayFeatures()()` The display features that are present in the window. |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/util/Set.html<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode>` | `[getEngagementModes](https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#getEngagementModes())()` **This method is deprecated.** Use WindowEngagementInfo#engagementModes instead |
| `final boolean` | `[hasEngagementMode](https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#hasEngagementMode(androidx.window.layout.WindowLayoutInfo.EngagementMode))(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode mode)` **This method is deprecated.** Use WindowEngagementInfo#hasEngagementMode instead |
| `final boolean` | `[hasEngagementModes](https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#hasEngagementModes(kotlin.Array))(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode... modes)` **This method is deprecated.** Use WindowEngagementInfo#hasEngagementModes instead |
| `int` | `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#hashCode()()` |
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#toString()()` |

## Public methods

### equals

```
public boolean equals(Object other)
```

### getDisplayFeatures

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

```
public final @NonNull List<@NonNull DisplayFeature> getDisplayFeatures()
```

The display features that are present in the window. It is an empty list if there are no display features.

### getEngagementModes

Added in [1.6.0-alpha05](https://developer.android.com/jetpack/androidx/releases/window#1.6.0-alpha05) Deprecated in [1.6.0-alpha05](https://developer.android.com/jetpack/androidx/releases/window#1.6.0-alpha05)

```
public final @NonNull Set<@NonNull WindowLayoutInfo.EngagementMode> [getEngagementModes](https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#getEngagementModes())()
```

> [!CAUTION]
> **This method is deprecated.**   
> Use WindowEngagementInfo#engagementModes instead

The current user engagement modes, indicating how the user is interacting with the app.

### hasEngagementMode

Added in [1.6.0-alpha05](https://developer.android.com/jetpack/androidx/releases/window#1.6.0-alpha05) Deprecated in [1.6.0-alpha05](https://developer.android.com/jetpack/androidx/releases/window#1.6.0-alpha05)

```
public final boolean [hasEngagementMode](https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#hasEngagementMode(androidx.window.layout.WindowLayoutInfo.EngagementMode))(@NonNull WindowLayoutInfo.EngagementMode mode)
```

> [!CAUTION]
> **This method is deprecated.**   
> Use WindowEngagementInfo#hasEngagementMode instead

Checks if a specific engagement mode is currently active.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode mode` | The `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode` to check for. |

| Returns |
|---|---|
| `boolean` | true if the mode is present in the `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#engagementModes()` set, false otherwise. |

### hasEngagementModes

Added in [1.6.0-alpha05](https://developer.android.com/jetpack/androidx/releases/window#1.6.0-alpha05) Deprecated in [1.6.0-alpha05](https://developer.android.com/jetpack/androidx/releases/window#1.6.0-alpha05)

```
public final boolean [hasEngagementModes](https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#hasEngagementModes(kotlin.Array))(@NonNull WindowLayoutInfo.EngagementMode... modes)
```

> [!CAUTION]
> **This method is deprecated.**   
> Use WindowEngagementInfo#hasEngagementModes instead

Checks if all specified engagement modes are currently active.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode... modes` | The `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo.EngagementMode`-s to check for. |

| Returns |
|---|---|
| `boolean` | true if all specified modes are in the `https://developer.android.com/reference/androidx/window/layout/WindowLayoutInfo#engagementModes()` set, false otherwise. |

### hashCode

```
public int hashCode()
```

### toString

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