Google은 흑인 공동체를 위한 인종 간 평등을 진전시키기 위해 노력하고 있습니다. Google에서 어떤 노력을 하고 있는지 확인하세요.

NavArgumentBuilder

class NavArgumentBuilder
kotlin.Any
   ↳ androidx.navigation.NavArgumentBuilder

DSL for constructing a new NavArgument

Summary

Public constructors

DSL for constructing a new NavArgument

Public methods
NavArgument

Builds the NavArgument by calling NavArgument.Builder.build.

Properties
Any?

An optional default value for this argument.

Boolean

Controls if this argument allows null values.

NavType<*>

Sets the NavType for this argument.

Public constructors

<init>

NavArgumentBuilder()

DSL for constructing a new NavArgument

Public methods

build

fun build(): NavArgument

Builds the NavArgument by calling NavArgument.Builder.build.

Properties

defaultValue

var defaultValue: Any?

An optional default value for this argument.

Any object that you set here must be compatible with type, if it was specified.

nullable

var nullable: Boolean

Controls if this argument allows null values.

type

var type: NavType<*>

Sets the NavType for this argument.

If you don't set a type explicitly, it will be inferred from the default value of this argument.