CookTrait.Unit

enum CookTrait.Unit : Enum, ClusterEnum


The available Units.

Summary

Enum Values

Centimeters

Centimeters.

Cups

Cups.

Deciliters

Deciliters.

Feet

Feet.

FluidOunces

FluidOunces.

Gallons

Gallons.

Grams

Grams.

Inches

Inches.

Kilograms

Kilograms.

Liters

Liters.

Meters

Meters.

Milligrams

Milligrams.

Milliliters

Milliliters.

Millimeters

Millimeters.

NoUnits

No units.

Ounces

Ounces.

Pinch

Pinch.

Pints

Pints.

Portion

Portion.

Pounds

Pounds.

Quarts

Quarts.

Tablespoons

Tablespoons.

Teaspoons

Teaspoons.

UnknownUnits

Unknown units.

UnknownValue

The enum value is out of range.

Public functions

String
CookTrait.Unit
valueOf(value: String)

Returns the enum constant of this type with the specified name.

Array<CookTrait.Unit>

Returns an array containing the constants of this enum type, in the order they're declared.

Public properties

open String

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

open String

Name of the Matter Data Type that the enum belongs to, in UpperCamelCase, e.g. "AlarmCodeEnum" from Door Lock Cluster.

open ULong

Integer identifier of the enum value per the Matter Application Clusters spec, e.g. 1 for Door Lock Cluster AlarmCodeEnum.LockFactoryReset.

Enum Values

Centimeters

val CookTrait.Unit.CentimetersCookTrait.Unit

Centimeters.

Deciliters

val CookTrait.Unit.DecilitersCookTrait.Unit

Deciliters.

FluidOunces

val CookTrait.Unit.FluidOuncesCookTrait.Unit

FluidOunces.

Gallons

val CookTrait.Unit.GallonsCookTrait.Unit

Gallons.

Grams

val CookTrait.Unit.GramsCookTrait.Unit

Grams.

Inches

val CookTrait.Unit.InchesCookTrait.Unit

Inches.

Kilograms

val CookTrait.Unit.KilogramsCookTrait.Unit

Kilograms.

Liters

val CookTrait.Unit.LitersCookTrait.Unit

Liters.

Meters

val CookTrait.Unit.MetersCookTrait.Unit

Meters.

Milligrams

val CookTrait.Unit.MilligramsCookTrait.Unit

Milligrams.

Milliliters

val CookTrait.Unit.MillilitersCookTrait.Unit

Milliliters.

Millimeters

val CookTrait.Unit.MillimetersCookTrait.Unit

Millimeters.

NoUnits

val CookTrait.Unit.NoUnitsCookTrait.Unit

No units.

Ounces

val CookTrait.Unit.OuncesCookTrait.Unit

Ounces.

Pinch

val CookTrait.Unit.PinchCookTrait.Unit

Pinch.

Pints

val CookTrait.Unit.PintsCookTrait.Unit

Pints.

Portion

val CookTrait.Unit.PortionCookTrait.Unit

Portion.

Pounds

val CookTrait.Unit.PoundsCookTrait.Unit

Pounds.

Quarts

val CookTrait.Unit.QuartsCookTrait.Unit

Quarts.

Tablespoons

val CookTrait.Unit.TablespoonsCookTrait.Unit

Tablespoons.

Teaspoons

val CookTrait.Unit.TeaspoonsCookTrait.Unit

Teaspoons.

UnknownUnits

val CookTrait.Unit.UnknownUnitsCookTrait.Unit

Unknown units.

UnknownValue

val CookTrait.Unit.UnknownValueCookTrait.Unit

The enum value is out of range. For example, a newer Matter cluster definition may support enum values not yet supported by the Home APIs.

Public functions

valueOf

fun valueOf(value: String): CookTrait.Unit

Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Throws
kotlin.IllegalArgumentException

if this enum type has no constant with the specified name

values

fun values(): Array<CookTrait.Unit>

Returns an array containing the constants of this enum type, in the order they're declared.

This method may be used to iterate over the constants.

Public properties

traitId

open val traitIdString

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

typeName

open val typeNameString

Name of the Matter Data Type that the enum belongs to, in UpperCamelCase, e.g. "AlarmCodeEnum" from Door Lock Cluster.

value

open val valueULong

Integer identifier of the enum value per the Matter Application Clusters spec, e.g. 1 for Door Lock Cluster AlarmCodeEnum.LockFactoryReset.