androidx.lifecycle.viewmodel.compose.serialization.serializers

Top-level functions summary

inline <Error class: unknown class><MutableState<T>>

Creates a KSerializer for a MutableState containing a Serializable value of type T.

Cmn
<Error class: unknown class><MutableState<T>>
<T : Any?> MutableStateSerializer(
    serializer: <Error class: unknown class><T>
)

Creates a KSerializer for a MutableState containing a Serializable value of type T.

Cmn

Top-level functions

MutableStateSerializer

inline fun <T : Any?> MutableStateSerializer(): <Error class: unknown class><MutableState<T>>

Creates a KSerializer for a MutableState containing a Serializable value of type T.

This inline function infers the state type T automatically and retrieves the appropriate KSerializer for serialization and deserialization of MutableState.

Parameters
<T : Any?>

The type of the value stored in the MutableState.

Returns
<Error class: unknown class><MutableState<T>>

A KSerializer for handling MutableState containing a Serializable type T.

MutableStateSerializer

fun <T : Any?> MutableStateSerializer(
    serializer: <Error class: unknown class><T>
): <Error class: unknown class><MutableState<T>>

Creates a KSerializer for a MutableState containing a Serializable value of type T.

This function allows for explicit specification of the KSerializer for the state type T. It provides serialization and deserialization capabilities for MutableState objects.

Parameters
<T : Any?>

The type of the value stored in the MutableState.

serializer: <Error class: unknown class><T>

The KSerializer for the Serializable type T.

Returns
<Error class: unknown class><MutableState<T>>

A KSerializer for handling MutableState containing a Serializable type T.