# SemanticsOwner

Artifact: [androidx.compose.ui:ui](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/semantics/SemanticsOwner.kt+class:androidx.compose.ui.semantics.SemanticsOwner) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.0.0) Common/AllAndroid/JVM
- Cmn

  ```
  class SemanticsOwner
  ```

*** ** * ** ***

Owns `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsNode` objects and notifies listeners of changes to the semantics tree

## Summary

| ### Public properties |
|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsNode` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsOwner#rootSemanticsNode()` The root node of the semantics tree. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsNode` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsOwner#unmergedRootSemanticsNode()` | Cmn |

| ### Extension functions |
|---|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsNode>` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsOwner.https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsOwner#(androidx.compose.ui.semantics.SemanticsOwner).getAllSemanticsNodes(kotlin.Boolean,kotlin.Boolean)( mergingEnabled: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html, skipDeactivatedNodes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html )` Finds all `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsNode`s in the tree owned by this `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsOwner`. | Cmn |

## Public properties

### rootSemanticsNode

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

```
val rootSemanticsNode: SemanticsNode
```

The root node of the semantics tree. Does not contain any unmerged data. May contain merged data.

### unmergedRootSemanticsNode

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

```
val unmergedRootSemanticsNode: SemanticsNode
```

## Extension functions

### SemanticsOwner.getAllSemanticsNodes

Cmn Artifact: [androidx.compose.ui:ui](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/semantics/SemanticsOwner.kt+function:getAllSemanticsNodes)

```
fun SemanticsOwner.getAllSemanticsNodes(
    mergingEnabled: Boolean,
    skipDeactivatedNodes: Boolean = true
): List<SemanticsNode>
```

Finds all `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsNode`s in the tree owned by this `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/SemanticsOwner`. Return the results in a list.

| Parameters |
|---|---|
| `mergingEnabled: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | set to true if you want the data to be merged. |
| `skipDeactivatedNodes: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html = true` | set to false if you want to collect the nodes which are deactivated. For example, the children of `https://developer.android.com/reference/kotlin/androidx/compose/ui/layout/SubcomposeLayout.composable#SubcomposeLayout(androidx.compose.ui.Modifier,kotlin.Function2)` which are retained to be reused in future are considered deactivated. |