# HomeEntityType


```
@HomeExperimentalApi
interface HomeEntityType : HomeObjectType, HasId, TraitProvider, PartsProvider
```

<br />

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

|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceGroup` | Domain entity representing a device group in the Home Graph. |

*** ** * ** ***

Common base interface for all first-class hydrated entities in the Home Graph.

## Summary

| ### Public properties |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/EntityTypeFactory<https://developers.home.google.com/reference/kotlin/com/google/home/HomeEntityType>` | `https://developers.home.google.com/reference/kotlin/com/google/home/HomeEntityType#factory()` The factory associated with this entity type. |
| `open https://developers.home.google.com/reference/kotlin/com/google/home/Id?` | `https://developers.home.google.com/reference/kotlin/com/google/home/HomeEntityType#structureId()` Id of the Structure if this entity is assigned to one. |

### Inherited functions

From [com.google.home.PartsProvider](https://developers.home.google.com/reference/kotlin/com/google/home/PartsProvider) `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<T>` `<T : https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType> https://developers.home.google.com/reference/kotlin/com/google/home/PartsProvider#part(com.google.home.DeviceTypeFactory,kotlin.Array)(type: https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory<T>, vararg tags: https://developers.home.google.com/reference/kotlin/com/google/home/Tag)`

Gets a flow on the `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType` using the given `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory` and `https://developers.home.google.com/reference/kotlin/com/google/home/Tag`.
`https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<T?>` `<T : https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType> https://developers.home.google.com/reference/kotlin/com/google/home/PartsProvider#partOrNull(com.google.home.DeviceTypeFactory,kotlin.Array)(type: https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory<T>, vararg tags: https://developers.home.google.com/reference/kotlin/com/google/home/Tag)`

Gets a flow on the `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType` using the given `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory` and `https://developers.home.google.com/reference/kotlin/com/google/home/Tag`.
`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/DeviceType>>` `https://developers.home.google.com/reference/kotlin/com/google/home/PartsProvider#parts()()`

Gets a flow on the `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType`s that are parts of this object.
From [com.google.home.TraitProvider](https://developers.home.google.com/reference/kotlin/com/google/home/TraitProvider) `open https://developers.home.google.com/reference/kotlin/com/google/home/Trait.TraitMetadata?` `<T : https://developers.home.google.com/reference/kotlin/com/google/home/Trait> https://developers.home.google.com/reference/kotlin/com/google/home/TraitProvider#metadata(com.google.home.TraitFactory)(traitFactory: https://developers.home.google.com/reference/kotlin/com/google/home/TraitFactory<T>)`

Access a specific trait metadata on the provider given a caller-provided TraitFactory.
`T?` `<T : https://developers.home.google.com/reference/kotlin/com/google/home/Trait> https://developers.home.google.com/reference/kotlin/com/google/home/TraitProvider#trait(com.google.home.TraitFactory)(traitFactory: https://developers.home.google.com/reference/kotlin/com/google/home/TraitFactory<T>)`

Access a specific trait on the provider given a caller-provided TraitFactory.
`open https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/Trait>` `https://developers.home.google.com/reference/kotlin/com/google/home/TraitProvider#traits()()`

Given a similar accessible trait set as the function above, returns a subset of those traits that are present in the associated `https://developers.home.google.com/reference/kotlin/com/google/home/HomeConfig#factoryRegistry()` union'ed with those already known to the extended sub-class (e.g specific DeviceType that is aware of the set of `https://developers.home.google.com/reference/kotlin/com/google/home/TraitFactory`s specified in its type definition).

### Inherited properties

From [com.google.home.HasConnectivityState](https://developers.home.google.com/reference/kotlin/com/google/home/HasConnectivityState) `https://developers.home.google.com/reference/kotlin/com/google/home/SourceConnectivity` `https://developers.home.google.com/reference/kotlin/com/google/home/HasConnectivityState#sourceConnectivity()`

Source Connectivity for the device.
From [com.google.home.HasId](https://developers.home.google.com/reference/kotlin/com/google/home/HasId) `https://developers.home.google.com/reference/kotlin/com/google/home/Id` `https://developers.home.google.com/reference/kotlin/com/google/home/HasId#id()`

Opaque ID for the object.

## Public properties

### factory

```
val factory: EntityTypeFactory<HomeEntityType>
```

The factory associated with this entity type.

### structureId

```
open val structureId: Id?
```

Id of the Structure if this entity is assigned to one.