SwitchTrait.Feature

data class SwitchTrait.Feature


Switch cluster FeatureMap.

Summary

Public constructors

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

Creates the Feature data class.

Public functions

open ULong

Convert this ClusterBitmap to raw (bytes) format

Public properties

Boolean
String

Name of the Matter bitmap, in UpperCamelCase, e.g. "OnOffControlBitmap" from OnOff Cluster.

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.

String

Trait identifier of the Matter Cluster that defines the bitmap Data Type.

Public constructors

Feature

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

Creates the Feature data class.

Public functions

toRaw

open fun toRaw(): ULong

Convert this ClusterBitmap to raw (bytes) format

Public properties

actionSwitch

val actionSwitchBoolean

bitmapName

val bitmapNameString

Name of the Matter bitmap, in UpperCamelCase, e.g. "OnOffControlBitmap" from OnOff Cluster.

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.

traitId

val traitIdString

Trait identifier of the Matter Cluster that defines the bitmap Data Type. Refer to ClusterId.traitId for the format.