CreatePolicy

屏幕创建策略

  1. New 直接创建新页面,并附加在导航栈顶,不共享任何资源和ViewModel。

  2. Replace 先在导航栈中查找原栈中最靠近栈顶的同类型条目,如果存在则将先其移除。触发New。

  3. Move 先在导航栈中查找原栈中最靠近栈顶的同类型条目,如果存在则将其直接移到导航栈顶,但不做任何更新操作;如果不存在则触发New。

  4. Resume 先在导航栈中查找原栈中最靠近栈顶的同类型条目,如果存在则将其直接移到导航栈顶,并调用页面的resume;如果不存在则触发New。

Entries

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Companion properties

Link copied to clipboard

Returns an immutable kotlin.enums.EnumEntries list containing the constants of this enum type, in the order they're declared.

Companion functions

Link copied to clipboard

Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Link copied to clipboard

Returns an array containing the constants of this enum type, in the order they're declared.

Properties

Link copied to clipboard
expect val name: String
Link copied to clipboard
expect val ordinal: Int

Functions

Link copied to clipboard
operator fun plus(policy: ClearPolicy): NavigationPolicy