PopUpToBuilder


@NavOptionsDsl
public final class PopUpToBuilder


DSL for customizing NavOptionsBuilder.popUpTo operations.

Summary

Public constructors

Public methods

final boolean

Whether the popUpTo destination should be popped from the back stack.

final boolean

Whether the back stack and the state of all destinations between the current destination and the NavOptionsBuilder.popUpTo ID should be saved for later restoration via NavOptionsBuilder.restoreState or the restoreState attribute using the same NavOptionsBuilder.popUpTo ID (note: this matching ID is true if inclusive is true.

final void
setInclusive(boolean inclusive)

Whether the popUpTo destination should be popped from the back stack.

final void
setSaveState(boolean saveState)

Whether the back stack and the state of all destinations between the current destination and the NavOptionsBuilder.popUpTo ID should be saved for later restoration via NavOptionsBuilder.restoreState or the restoreState attribute using the same NavOptionsBuilder.popUpTo ID (note: this matching ID is true if inclusive is true.

Public constructors

PopUpToBuilder

Added in 2.4.0
public PopUpToBuilder()

Public methods

getInclusive

Added in 2.4.0
public final boolean getInclusive()

Whether the popUpTo destination should be popped from the back stack.

getSaveState

Added in 2.4.0
public final boolean getSaveState()

Whether the back stack and the state of all destinations between the current destination and the NavOptionsBuilder.popUpTo ID should be saved for later restoration via NavOptionsBuilder.restoreState or the restoreState attribute using the same NavOptionsBuilder.popUpTo ID (note: this matching ID is true if inclusive is true. If inclusive is false, this matching ID is the id of the last destination that is popped).

setInclusive

Added in 2.4.0
public final void setInclusive(boolean inclusive)

Whether the popUpTo destination should be popped from the back stack.

setSaveState

Added in 2.4.0
public final void setSaveState(boolean saveState)

Whether the back stack and the state of all destinations between the current destination and the NavOptionsBuilder.popUpTo ID should be saved for later restoration via NavOptionsBuilder.restoreState or the restoreState attribute using the same NavOptionsBuilder.popUpTo ID (note: this matching ID is true if inclusive is true. If inclusive is false, this matching ID is the id of the last destination that is popped).