Package-level declarations

The annotation set, split by what the annotated declaration is.

  • @NavDestination marks a presenter the navigator can route to, as a screen, an overlay or a tab

  • @ChildPresenter marks a presenter that needs a graph but is built by its parent rather than routed to

  • @AppRoot marks the root of the navigation tree

  • @ScreenUi, @SheetUi, @TabUi and @AppRootUi mark the composables that render them

Each annotation's own documentation lists the files it generates and the errors the processor reports for it.

Types

Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.CLASS])
annotation class AppRoot(val parentScope: KClass<*>)

Marks an @AssistedInject presenter implementation as the application's root host, so the codegen processor can wire its bound interface into parentScope at compile time.

Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.FUNCTION])
annotation class AppRootUi(val presenter: KClass<*>, val parentScope: KClass<*>)

Marks a @Composable function as the application's root host composable, so the codegen processor can emit a provider interface and an extension that the activity's dependency graph implements.

Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.CLASS])
annotation class ChildPresenter(val scope: KClass<*>, val parentScope: KClass<*>)

Marks a presenter class as a child presenter exposed through a graph extension scoped to its parent host (typically a tab pager presenter).

Link copied to clipboard

The role a NavDestination plays at runtime. The processor uses this value to choose which pair of files to emit and which NavDestination subclass the generated binding contributes to.

Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.CLASS])
annotation class NavDestination(val route: KClass<*>, val parentScope: KClass<*>, val kind: DestinationKind)

Marks a presenter class as a navigation destination so the codegen processor can wire it into the consumer's navigation graph at compile time.

Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.FUNCTION])
annotation class ScreenUi(val presenter: KClass<*>, val parentScope: KClass<*>)

Marks a @Composable function as the Android renderer for a screen presenter, so the codegen processor can wire it into the consumer's UI multibinding at compile time.

Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.FUNCTION])
annotation class SheetUi(val presenter: KClass<*>, val parentScope: KClass<*>)

Marks a @Composable function as the Android renderer for a modal overlay presenter, so the codegen processor can wire it into the consumer's overlay multibinding at compile time.

Link copied to clipboard
@Target(allowedTargets = [AnnotationTarget.FUNCTION])
annotation class TabUi(val presenter: KClass<*>, val parentScope: KClass<*>)

Marks a @Composable function as the Android renderer for a tab-root presenter.