NavActionBuilder

@NavDestinationDsl
public final class NavActionBuilder


DSL for building a NavAction.

Summary

Public constructors

Public methods

final @NonNull Map<@NonNull StringObject>

The set of default arguments that should be passed to the destination.

final int

The ID of the destination that should be navigated to when this action is used

final void
navOptions(
    @ExtensionFunctionType @NonNull Function1<@NonNull NavOptionsBuilderUnit> optionsBuilder
)

Sets the NavOptions for this action that should be used by default

final void
setDestinationId(int destinationId)

The ID of the destination that should be navigated to when this action is used

Public constructors

Added in 1.0.0
public NavActionBuilder()

Public methods

getDefaultArguments

Added in 2.3.0
public final @NonNull Map<@NonNull StringObjectgetDefaultArguments()

The set of default arguments that should be passed to the destination. The keys used here should be the same as those used on the NavDestinationBuilder.argument for the destination.

All values added here should be able to be added to a android.os.Bundle.

See also
NavAction.getDefaultArguments

getDestinationId

Added in 1.0.0
public final int getDestinationId()

The ID of the destination that should be navigated to when this action is used

Added in 1.0.0
public final void navOptions(
    @ExtensionFunctionType @NonNull Function1<@NonNull NavOptionsBuilderUnit> optionsBuilder
)

Sets the NavOptions for this action that should be used by default

setDestinationId

Added in 1.0.0
public final void setDestinationId(int destinationId)

The ID of the destination that should be navigated to when this action is used