public final class EntryClassProvider<T extends Object>


Holds a Entry class, metadata, and content for that class

Parameters
<T extends Object>

the type of the key for this NavEntry

Summary

Public constructors

<T extends Object> EntryClassProvider(
    @NonNull KClass<@NonNull T> clazz,
    @NonNull Function1<@NonNull key, @NonNull Object> clazzContentKey,
    @NonNull Map<@NonNull String, @NonNull Object> metadata,
    @Composable @NonNull Function1<@NonNull T, Unit> content
)

Public methods

final @NonNull KClass<@NonNull T>

the KClass of the key for this NavEntry

final @NonNull Function1<@NonNull key, @NonNull Object>

A factory of unique, stable ids that uniquely identifies the content of this NavEntry.

final @Composable @NonNull Function1<@NonNull T, Unit>

content for this entry to be displayed when this entry is active

final @NonNull Map<@NonNull String, @NonNull Object>

provides information to the display

Public constructors

EntryClassProvider

public <T extends Object> EntryClassProvider(
    @NonNull KClass<@NonNull T> clazz,
    @NonNull Function1<@NonNull key, @NonNull Object> clazzContentKey,
    @NonNull Map<@NonNull String, @NonNull Object> metadata,
    @Composable @NonNull Function1<@NonNull T, Unit> content
)
Parameters
<T extends Object>

the type of the key for this NavEntry

@NonNull KClass<@NonNull T> clazz

the KClass of the key for this NavEntry

@NonNull Function1<@NonNull key, @NonNull Object> clazzContentKey

A factory of unique, stable ids that uniquely identifies the content of this NavEntry. To maximize stability, it should ge derived from the factory's provided key. The resulting key must be saveable (i.e. on Android, it should be saveable via Android). The generated key will be stored in NavEntry.contentKey.

@NonNull Map<@NonNull String, @NonNull Object> metadata

provides information to the display

@Composable @NonNull Function1<@NonNull T, Unit> content

content for this entry to be displayed when this entry is active

Public methods

getClazz

Added in 1.0.0-alpha04
public final @NonNull KClass<@NonNull T> getClazz()

the KClass of the key for this NavEntry

getClazzContentKey

Added in 1.0.0-alpha04
public final @NonNull Function1<@NonNull key, @NonNull ObjectgetClazzContentKey()

A factory of unique, stable ids that uniquely identifies the content of this NavEntry. To maximize stability, it should ge derived from the factory's provided key. The resulting key must be saveable (i.e. on Android, it should be saveable via Android). The generated key will be stored in NavEntry.contentKey.

getContent

Added in 1.0.0-alpha04
public final @Composable @NonNull Function1<@NonNull T, UnitgetContent()

content for this entry to be displayed when this entry is active

getMetadata

Added in 1.0.0-alpha04
public final @NonNull Map<@NonNull String, @NonNull ObjectgetMetadata()

provides information to the display