Android 12 Developer Preview is here! Try it out, and give us your feedback!

MutableObservableWatchData

class MutableObservableWatchData<T : Any> : ObservableWatchData<T>
kotlin.Any
   ↳ androidx.wear.watchface.ObservableWatchData<T>
   ↳ androidx.wear.watchface.MutableObservableWatchData

ObservableWatchData which publicly exposes setValueT method.

Summary

Public constructors

<init>(initialValue: T?)

ObservableWatchData which publicly exposes setValueT method.

Inherited functions
Properties
T

Mutable observable value.

Public constructors

<init>

MutableObservableWatchData()

<init>

MutableObservableWatchData(initialValue: T?)

ObservableWatchData which publicly exposes setValueT method.

Parameters
T The type of data held by this instance

Properties

value

var value: T

Mutable observable value. Assigning a different value will trigger Observer.onChanged callbacks.