FrontendViewModel

abstract class FrontendViewModel<P : AnyPanel>(val panel: P) : LifecycleViewModel

A ViewModel that references the panel that hosts this ViewModel.

Parameters

P

The type of the panel.

Constructors

Link copied to clipboard
fun <P : AnyPanel> FrontendViewModel(panel: P)

Types

Link copied to clipboard
open class Factory(panel: AnyPanel) : ViewModelProvider.Factory

A factory class for constructing class instances that derive from FrontendViewModel with the given panel.

Properties

Link copied to clipboard
val isSafetyLockEnabled: LiveData<Boolean>

Whether or not safety lock is currently enabled.

Link copied to clipboard
val panel: P

The Panel of type P that hosts this ViewModel.

Inherited functions

Link copied to clipboard
open fun addCloseable(@NonNull p0: Closeable)
Link copied to clipboard
override fun getLifecycle(): Lifecycle

Inheritors

Link copied to clipboard