ViewElement

@JsonClass(generateAdapter = true)
data class ViewElement(val id: UUID = UUID.randomUUID(), val x: Int, val y: Int, val width: Int, val height: Int, val type: String, val displayName: String?, val selector: ElementSelector?, val children: List<ViewElement>?)

Represents a view in the layout hierarchy of the application.

The view information provided in this structure provides screen capture metadata to Appcues servers that can be used for element targeted experiences. The layout information is used by the Appcues Mobile Builder to select and target UI elements, and used by the Appcues Android SDK to position experience content relative to targeted elements.

Constructors

Link copied to clipboard
constructor(id: UUID = UUID.randomUUID(), x: Int, y: Int, width: Int, height: Int, type: String, displayName: String?, selector: ElementSelector?, children: List<ViewElement>?)

Properties

Link copied to clipboard

The sub-views contained within this view, if any.

Link copied to clipboard

A value representing the display name of the view.

Link copied to clipboard
val height: Int

The height of the view.

Link copied to clipboard
val id: UUID

Auto-generated unique ID for the view.

Link copied to clipboard

The element selector details that can be used to target content to this view. The selector structure depends on the UI toolkit in use. If no identifiable properties exist for this view, this selector value should be null.

Link copied to clipboard

A value representing the type of the view.

Link copied to clipboard
val width: Int

The width of the view.

Link copied to clipboard
val x: Int

The x-coordinate for view position, with origin in the upper-left corner. This value is in screen coordinates, not relative to the parent.

Link copied to clipboard
val y: Int

The y-coordinate for view position, with origin is in the upper-left corner. This value is in screen coordinates, not relative to the parent.