EntryProviderScope
-
Cmn
@EntryDsl
class EntryProviderScope<T : Any>
The scope for constructing a new NavEntry with Kotlin DSL
Summary
Public constructors |
|
|---|---|
<T : Any> EntryProviderScope(fallback: (unknownScreen) -> NavEntry<T>) |
Cmn
|
Public functions |
||
|---|---|---|
Unit |
<K : T> addEntryProvider(Builds a |
Cmn
|
Unit |
<K : T> addEntryProvider(Builds a |
Cmn
|
Unit |
<K : T> addEntryProvider( |
Cmn
|
Unit |
<K : T> addEntryProvider( |
Cmn
|
inline Unit |
<K : T> entry(Add an entry provider to the |
Cmn
|
inline Unit |
<K : T> entry(Add an entry provider to the |
Cmn
|
Unit |
<K : T> EntryProviderScope<T>.entry(Add an entry provider to the |
Cmn
|
Unit |
<K : T> EntryProviderScope<T>.entry(Add an entry provider to the |
Cmn
|
Public constructors
Public functions
addEntryProvider
fun <K : T> addEntryProvider(
clazz: KClass<K>,
clazzContentKey: (key) -> Any = { defaultContentKey(it) },
metadata: (K) -> Map<String, Any>,
content: @Composable (K) -> Unit
): Unit
Builds a NavEntry for the given clazz that displays content.
| Parameters | |
|---|---|
<K : T> |
the type of the key for this NavEntry |
clazz: KClass<K> |
the KClass |
clazzContentKey: (key) -> Any = { defaultContentKey(it) } |
A factory of unique, stable ids that uniquely identifies the content of this NavEntry. To maximize stability, it should be 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 |
metadata: (K) -> Map<String, Any> |
lambda that takes the key and provides a map of additional info |
content: @Composable (K) -> Unit |
content for this entry to be displayed when this entry is active |
addEntryProvider
fun <K : T> addEntryProvider(
clazz: KClass<K>,
clazzContentKey: (key) -> Any = { defaultContentKey(it) },
metadata: Map<String, Any> = emptyMap(),
content: @Composable (K) -> Unit
): Unit
Builds a NavEntry for the given clazz that displays content.
| Parameters | |
|---|---|
<K : T> |
the type of the key for this NavEntry |
clazz: KClass<K> |
the KClass |
clazzContentKey: (key) -> Any = { defaultContentKey(it) } |
A factory of unique, stable ids that uniquely identifies the content of this NavEntry. To maximize stability, it should be 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 |
metadata: Map<String, Any> = emptyMap() |
provides information to the display |
content: @Composable (K) -> Unit |
content for this entry to be displayed when this entry is active |
addEntryProvider
fun <K : T> addEntryProvider(
key: K,
contentKey: Any = defaultContentKey(key),
metadata: (K) -> Map<String, Any>,
content: @Composable (K) -> Unit
): Unit
Builds a NavEntry for the given key that displays content.
| Parameters | |
|---|---|
<K : T> |
the type of the key for this NavEntry |
key: K |
key for this entry |
contentKey: Any = defaultContentKey(key) |
A unique, stable id that uniquely identifies the content of this NavEntry. To maximize stability, it should be derived from the |
metadata: (K) -> Map<String, Any> |
lambda that takes the |
content: @Composable (K) -> Unit |
content for this entry to be displayed when this entry is active |
addEntryProvider
fun <K : T> addEntryProvider(
key: K,
contentKey: Any = defaultContentKey(key),
metadata: Map<String, Any> = emptyMap(),
content: @Composable (K) -> Unit
): Unit
Builds a NavEntry for the given key that displays content.
| Parameters | |
|---|---|
<K : T> |
the type of the key for this NavEntry |
key: K |
key for this entry |
contentKey: Any = defaultContentKey(key) |
A unique, stable id that uniquely identifies the content of this NavEntry. To maximize stability, it should be derived from the |
metadata: Map<String, Any> = emptyMap() |
provides information to the display |
content: @Composable (K) -> Unit |
content for this entry to be displayed when this entry is active |
entry
inline fun <K : T> entry(
noinline clazzContentKey: (key) -> Any = { defaultContentKey(it) },
noinline metadata: (K) -> Map<String, Any>,
noinline content: @Composable (K) -> Unit
): Unit
Add an entry provider to the EntryProviderScope
| Parameters | |
|---|---|
<K : T> |
the type of the key for this NavEntry |
noinline clazzContentKey: (key) -> Any = { defaultContentKey(it) } |
A factory of unique, stable ids that uniquely identifies the content of this NavEntry. To maximize stability, it should be 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 |
noinline metadata: (K) -> Map<String, Any> |
lambda that takes the key and provides a map of additional info |
noinline content: @Composable (K) -> Unit |
content for this entry to be displayed when this entry is active |
entry
inline fun <K : T> entry(
noinline clazzContentKey: (key) -> Any = { defaultContentKey(it) },
metadata: Map<String, Any> = emptyMap(),
noinline content: @Composable (K) -> Unit
): Unit
Add an entry provider to the EntryProviderScope
| Parameters | |
|---|---|
<K : T> |
the type of the key for this NavEntry |
noinline clazzContentKey: (key) -> Any = { defaultContentKey(it) } |
A factory of unique, stable ids that uniquely identifies the content of this NavEntry. To maximize stability, it should be 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 |
metadata: Map<String, Any> = emptyMap() |
provides information to the display |
noinline content: @Composable (K) -> Unit |
content for this entry to be displayed when this entry is active |
EntryProviderScope.entry
fun <K : T> EntryProviderScope<T>.entry(
key: K,
contentKey: Any = defaultContentKey(key),
metadata: (K) -> Map<String, Any>,
content: @Composable (K) -> Unit
): Unit
Add an entry provider to the EntryProviderScope
| Parameters | |
|---|---|
<K : T> |
the type of the key for this NavEntry |
key: K |
key for this entry |
contentKey: Any = defaultContentKey(key) |
A unique, stable id that uniquely identifies the content of this NavEntry. To maximize stability, it should be derived from the |
metadata: (K) -> Map<String, Any> |
lambda that takes the |
content: @Composable (K) -> Unit |
content for this entry to be displayed when this entry is active |
EntryProviderScope.entry
fun <K : T> EntryProviderScope<T>.entry(
key: K,
contentKey: Any = defaultContentKey(key),
metadata: Map<String, Any> = emptyMap(),
content: @Composable (K) -> Unit
): Unit
Add an entry provider to the EntryProviderScope
| Parameters | |
|---|---|
<K : T> |
the type of the key for this NavEntry |
key: K |
key for this entry |
contentKey: Any = defaultContentKey(key) |
A unique, stable id that uniquely identifies the content of this NavEntry. To maximize stability, it should be derived from the |
metadata: Map<String, Any> = emptyMap() |
provides information to the display |
content: @Composable (K) -> Unit |
content for this entry to be displayed when this entry is active |