# OnOff.Command

# OnOff.Command


```
enum OnOff.Command : Enum
```

<br />

|---|---|---|
| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html) |||
| ↳ | [kotlin.Enum](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-enum/index.html) ||
|   | ↳ | [com.google.home.matter.standard.OnOff.Command](https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command) |

*** ** * ** ***

Descriptor enum for this trait's commands.

## Summary

| ### Enum Values |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#Off` | The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#off()` trait command. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#OffWithEffect` | The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#offWithEffect(com.google.home.matter.standard.OnOffTrait.EffectIdentifierEnum,kotlin.UByte)` trait command. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#On` | The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#on()` trait command. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#OnWithRecallGlobalScene` | The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#onWithRecallGlobalScene()` trait command. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#OnWithTimedOff` | The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#onWithTimedOff(com.google.home.matter.standard.OnOffTrait.OnOffControlBitmap,kotlin.UShort,kotlin.UShort)` trait command. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#Toggle` | The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#toggle()` trait command. |

| ### Public functions |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command` | `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#valueOf(kotlin.String)(value: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` Returns the enum constant of this type with the specified name. |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-array/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command>` | `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#values()()` Returns an array containing the constants of this enum type, in the order they're declared. |

| ### Public properties |
|---|---|
| `https://developers.home.google.com/reference/kotlin/kotlin/enums/EnumEntries<https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command>` | `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#entries()` Returns a representation of an immutable list of all enum entries, in the order they're declared. |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-u-int/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOff.Command#tag()` |

## Enum Values

### Off

```
val OnOff.Command.Off: OnOff.Command
```

The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#off()` trait command.

### OffWithEffect

```
val OnOff.Command.OffWithEffect: OnOff.Command
```

The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#offWithEffect(com.google.home.matter.standard.OnOffTrait.EffectIdentifierEnum,kotlin.UByte)` trait command.

### On

```
val OnOff.Command.On: OnOff.Command
```

The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#on()` trait command.

### OnWithRecallGlobalScene

```
val OnOff.Command.OnWithRecallGlobalScene: OnOff.Command
```

The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#onWithRecallGlobalScene()` trait command.

### OnWithTimedOff

```
val OnOff.Command.OnWithTimedOff: OnOff.Command
```

The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#onWithTimedOff(com.google.home.matter.standard.OnOffTrait.OnOffControlBitmap,kotlin.UShort,kotlin.UShort)` trait command.

### Toggle

```
val OnOff.Command.Toggle: OnOff.Command
```

The `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/OnOffCommands#toggle()` trait command.

## Public functions

### valueOf

```
fun valueOf(value: String): OnOff.Command
```

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 |
|---|---|
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-illegal-argument-exception/index.html` | if this enum type has no constant with the specified name |

### values

```
fun values(): Array<OnOff.Command>
```

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

### entries

```
val entries: EnumEntries<OnOff.Command>
```

Returns a representation of an immutable list of all enum entries, in the order they're declared.

This method may be used to iterate over the enum entries.

### tag

```
val tag: UInt
```