SemanticsNode

class SemanticsNode
kotlin.Any
   ↳ androidx.ui.core.semantics.SemanticsNode

A node that represents some semantic data.

Summary

Public constructors

<init>(unmergedConfig: SemanticsConfiguration, componentNode: SemanticsComponentNode)

Creates a semantic node.

Companion functions

Int

Extension functions

From androidx.ui.core
SemanticsNode?

Executes selector on every parent of this SemanticsNode and returns the closest SemanticsNode to return true from selector or null if selector returns false for all ancestors.

Inherited extension functions

From androidx.compose
operator T

IMPORTANT: This global operator is TEMPORARY, and should be removed whenever an answer for contextual composers is reached.

Properties

Boolean

Whether this node is in a tree whose root is attached to something.

PxBounds

The bounding box for this node relative to the root of this Compose hierarchy

List<SemanticsNode>

Contains the children in inverse hit test order (i.

ComponentNode

SemanticsConfiguration

The merged configuration of this node

PxBounds

Boolean

Whether this node has a non-zero number of children.

Int

The unique identifier for this node.

Boolean

SemanticsNode?

The parent of this node in the tree.

PxSize

The size of the bounding box for this node

List<SemanticsNode>

SemanticsConfiguration

Public constructors

<init>

SemanticsNode(
    unmergedConfig: SemanticsConfiguration,
    componentNode: SemanticsComponentNode)

Creates a semantic node.

Each semantic node has a unique identifier that is assigned when the node is created.

Properties

attached

val attached: Boolean

Whether this node is in a tree whose root is attached to something.

This becomes true during the call to attach.

This becomes false during the call to detach.

boundsInRoot

val boundsInRoot: PxBounds

The bounding box for this node relative to the root of this Compose hierarchy

children

val children: List<SemanticsNode>

Contains the children in inverse hit test order (i.e. paint order).

componentNode

var componentNode: ComponentNode

config

val config: SemanticsConfiguration

The merged configuration of this node

globalBounds

val globalBounds: PxBounds

hasChildren

val hasChildren: Boolean

Whether this node has a non-zero number of children.

id

val id: Int

The unique identifier for this node.

The root node has an id of zero. Other nodes are given a unique id when they are created.

isSemanticBoundary

val isSemanticBoundary: Boolean

parent

var parent: SemanticsNode?

The parent of this node in the tree.

size

val size: PxSize

The size of the bounding box for this node

unmergedChildren

val unmergedChildren: List<SemanticsNode>

unmergedConfig

var unmergedConfig: SemanticsConfiguration

Companion functions

generateNewId

fun generateNewId(): Int