ObservableWatchData.MutableObservableWatchData

public final class ObservableWatchData.MutableObservableWatchData<T extends Object> extends ObservableWatchData


ObservableWatchData which publicly exposes setValue(T) method.

Parameters
<T extends Object>

The type of data held by this instance

Summary

Public fields

@NonNull T

Mutable observable value.

Public constructors

<T extends Object> MutableObservableWatchData(@Nullable T initialValue)

Inherited methods

From class ObservableWatchData
final @UiThread void

Adds the given Observer to the observers list.

final @UiThread @NonNull T
getValueOr(@NonNull T default)

Returns the value contained within this ObservableWatchData or default if there isn't one.

final @UiThread boolean

Whether or not this ObservableWatchData contains a value.

final @UiThread void

Removes an observer previously added by addObserver.

@NonNull String

Public fields

value

@NonNull
public @NonNullvalue

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

Public constructors

MutableObservableWatchData

public final <T extends Object> MutableObservableWatchData()

MutableObservableWatchData

public final <T extends Object> MutableObservableWatchData(@Nullable T initialValue)
Parameters
<T extends Object>

The type of data held by this instance