# ClosureControlTrait.OverallTargetStateStruct

# ClosureControlTrait.OverallTargetStateStruct


```
class ClosureControlTrait.OverallTargetStateStruct : ClusterStruct
```

<br />

*** ** * ** ***

The target state of the closure.

## Summary

| ### Nested types |
|---|
| `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalGenericApi enum https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.OverallTargetStateStruct.StructFields : https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-enum/index.html, https://developers.home.google.com/reference/kotlin/com/google/home/Field` Descriptor enum for this struct's fields. |

| ### Public constructors |
|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.OverallTargetStateStruct#OverallTargetStateStruct(com.google.home.matter.serialization.OptionalValue,com.google.home.matter.serialization.OptionalValue,com.google.home.matter.serialization.OptionalValue)( position: https://developers.home.google.com/reference/kotlin/com/google/home/matter/serialization/OptionalValue<https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.TargetPositionEnum?>, latch: https://developers.home.google.com/reference/kotlin/com/google/home/matter/serialization/OptionalValue<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html?>, speed: https://developers.home.google.com/reference/kotlin/com/google/home/matter/serialization/OptionalValue<https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.ThreeLevelAutoEnum> )` Creates the OverallTargetStateStruct class. |

| ### Public functions |
|---|---|
| `open https://developers.home.google.com/reference/kotlin/com/google/home/StructDescriptor` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalGenericApi https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.OverallTargetStateStruct#getDescriptor()()` Returns the descriptor for the struct. |
| `open https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html?` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalGenericApi https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.OverallTargetStateStruct#getFieldValueById(kotlin.UInt)(tagId: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-u-int/index.html)` Returns the value of the field for the given tag ID. |

| ### Public properties |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/serialization/OptionalValue<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html?>` | `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.OverallTargetStateStruct#latch()` The desired latching state of the closure. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/serialization/OptionalValue<https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.TargetPositionEnum?>` | `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.OverallTargetStateStruct#position()` The target position that the closure is moving to. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/matter/serialization/OptionalValue<https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.ThreeLevelAutoEnum>` | `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.OverallTargetStateStruct#speed()` The desired speed at which the closure should perform the movement toward the target position. |

## Public constructors

### OverallTargetStateStruct

```
OverallTargetStateStruct(
    position: OptionalValue<ClosureControlTrait.TargetPositionEnum?> = OptionalValue.absent(),
    latch: OptionalValue<Boolean?> = OptionalValue.absent(),
    speed: OptionalValue<ClosureControlTrait.ThreeLevelAutoEnum> = OptionalValue.absent()
)
```

Creates the OverallTargetStateStruct class.

## Public functions

### getDescriptor

```
@HomeExperimentalGenericApi
open fun getDescriptor(): StructDescriptor
```

Returns the descriptor for the struct.

### getFieldValueById

```
@HomeExperimentalGenericApi
open fun getFieldValueById(tagId: UInt): Any?
```

Returns the value of the field for the given tag ID.

## Public properties

### latch

```
val latch: OptionalValue<Boolean?>
```

The desired latching state of the closure. A null value indicates that there is no desired latching state.

### position

```
val position: OptionalValue<ClosureControlTrait.TargetPositionEnum?>
```

The target position that the closure is moving to. A null value indicates there is no target position.

### speed

```
val speed: OptionalValue<ClosureControlTrait.ThreeLevelAutoEnum>
```

The desired speed at which the closure should perform the movement toward the target position. If no speed value has yet been set, the server sets one of the speed values defined in `https://developers.home.google.com/reference/kotlin/com/google/home/matter/standard/ClosureControlTrait.ThreeLevelAutoEnum`.