# HasCandidates


```
interface HasCandidates
```

<br />

Known direct subclasses [DeviceGroup](https://developers.home.google.com/reference/kotlin/com/google/home/DeviceGroup), [HomeDevice](https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice), [Room](https://developers.home.google.com/reference/kotlin/com/google/home/Room), [Structure](https://developers.home.google.com/reference/kotlin/com/google/home/Structure)

|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceGroup` | Domain entity representing a device group in the Home Graph. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` | A device supporting traits, commands, and subscriptions. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Room` | An object that represents a Room in a `https://developers.home.google.com/reference/kotlin/com/google/home/Structure`. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Structure` | The top-level organizing construct for the `https://developers.home.google.com/reference/kotlin/com/google/home/Home`. |

*** ** * ** ***

Interface that provides discovery functions.

## Summary

| ### Public functions |
|---|---|
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/automation/NodeCandidate>>` | `https://developers.home.google.com/reference/kotlin/com/google/home/automation/HasCandidates#allCandidates()()` Returns all the automation `https://developers.home.google.com/reference/kotlin/com/google/home/automation/NodeCandidate` instances for the receiver and its child objects. |
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/automation/NodeCandidate>>` | `https://developers.home.google.com/reference/kotlin/com/google/home/automation/HasCandidates#candidates()()` Returns all the automation `https://developers.home.google.com/reference/kotlin/com/google/home/automation/NodeCandidate` instances for the receiver. |

## Public functions

### allCandidates

```
fun allCandidates(): Flow<Set<NodeCandidate>>
```

Returns all the automation `https://developers.home.google.com/reference/kotlin/com/google/home/automation/NodeCandidate` instances for the receiver and its child objects.

### candidates

```
fun candidates(): Flow<Set<NodeCandidate>>
```

Returns all the automation `https://developers.home.google.com/reference/kotlin/com/google/home/automation/NodeCandidate` instances for the receiver.