androidx.a2ui.engine.catalog


Interfaces

A2uiCoreCatalog

A registry of UI components and functions that a client surface can render.

A2uiCoreComponentDefinition

Defines a single UI component and its schema.

A2uiCoreComponentDefinitionCollection

An immutable, indexed collection of A2uiCoreComponentDefinitions registered within an A2uiCoreCatalog.

Classes

A2uiCoreCatalogSerializer

Serializes an A2uiCoreCatalog into JSON Schema representations.

Top-level functions summary

Extension functions summary

A2uiCoreCatalogSerializer

Creates an A2uiCoreCatalogSerializer for this catalog.

A2uiInlineCatalog

Adapts this A2uiCoreCatalog into an A2uiInlineCatalog for use in client capabilities advertisement.

A2uiSchema

Converts this component definition into an A2uiSchema.

Top-level functions

A2uiCoreComponentDefinitionCollection

fun A2uiCoreComponentDefinitionCollection(
    definitions: List<A2uiCoreComponentDefinition> = emptyList()
): A2uiCoreComponentDefinitionCollection

Creates an immutable A2uiCoreComponentDefinitionCollection from a list of A2uiCoreComponentDefinitions.

Parameters
definitions: List<A2uiCoreComponentDefinition> = emptyList()

The list of component definitions to include.

Throws
IllegalArgumentException

If duplicate component definition names are detected.

Extension functions

A2uiCoreCatalog.obtainSerializer

fun A2uiCoreCatalog.obtainSerializer(): A2uiCoreCatalogSerializer

Creates an A2uiCoreCatalogSerializer for this catalog.

Returns
A2uiCoreCatalogSerializer

a new serializer instance configured for this catalog

A2uiCoreCatalog.toInlineCatalog

fun A2uiCoreCatalog.toInlineCatalog(): A2uiInlineCatalog

Adapts this A2uiCoreCatalog into an A2uiInlineCatalog for use in client capabilities advertisement.

Throws
IllegalStateException

If isInline is false.

A2uiCoreComponentDefinition.toSchema

fun A2uiCoreComponentDefinition.toSchema(): A2uiSchema

Converts this component definition into an A2uiSchema.

Returns
A2uiSchema

the A2uiSchema representation of this component definition