SwitchTrait.Feature

data class SwitchTrait.Feature : ClusterBitmap


Switch cluster FeatureMap.

Summary

Public constructors

Feature(
    latchingSwitch: Boolean,
    momentarySwitch: Boolean,
    momentarySwitchRelease: Boolean,
    momentarySwitchLongPress: Boolean,
    momentarySwitchMultiPress: Boolean
)

Creates the Feature data class.

Public functions

open ULong

Public properties

Boolean

The latching switch (such as a rocker) maintains its position after being pressed or turned.

Boolean

The momentary switch (such as a push button) does not maintain its position after being pressed or turned.

Boolean

The momentary switch (such as a push button) can distinguish and report long pressed from short presses.

Boolean

The momentary switch (such as a push button) can distinguish and report double press and potentially multiple presses with more events, such as a triple press.

Boolean

The momentary switch (such as a push button) can distinguish and report release events.

Public constructors

Feature

Feature(
    latchingSwitch: Boolean = false,
    momentarySwitch: Boolean = false,
    momentarySwitchRelease: Boolean = false,
    momentarySwitchLongPress: Boolean = false,
    momentarySwitchMultiPress: Boolean = false
)

Creates the Feature data class.

Public functions

toRaw

open fun toRaw(): ULong

Public properties

latchingSwitch

val latchingSwitchBoolean

The latching switch (such as a rocker) maintains its position after being pressed or turned.

momentarySwitch

val momentarySwitchBoolean

The momentary switch (such as a push button) does not maintain its position after being pressed or turned. After releasing, it goes back to its idle position.

momentarySwitchLongPress

val momentarySwitchLongPressBoolean

The momentary switch (such as a push button) can distinguish and report long pressed from short presses.

momentarySwitchMultiPress

val momentarySwitchMultiPressBoolean

The momentary switch (such as a push button) can distinguish and report double press and potentially multiple presses with more events, such as a triple press.

momentarySwitchRelease

val momentarySwitchReleaseBoolean

The momentary switch (such as a push button) can distinguish and report release events.