RootNodeDevice

class RootNodeDevice : DeviceType


A utility device type required for all nodes in a fabric whose main function is to describe the node and what endpoints the node supports.

Summary

Nested types

Trait Container for Standard Traits.

Public constructors

RootNodeDevice(
    metadata: DeviceType.Metadata,
    traitProvider: TraitProvider,
    eventProvider: HasEvents,
    standardTraits: RootNodeDevice.StandardTraits
)

Creates the RootNodeDevice class.

Inherited functions

open Flow<Event>

Gets a flow of all Events available for the object.

open Flow<T>
<T : Event> events(event: EventFactory<T>)

Gets a flow of a specific Event.

open Flow<Event>
<T : Trait> events(trait: TraitFactory<T>)

Gets a flow of all Events by this Trait.

open T?
<T : Trait> trait(traitFactory: TraitFactory<T>)

Access a specific trait on the provider given a caller-provided TraitFactory.

open Set<Trait>

Given a similar accessible trait set as the function above, returns a subset of those traits that are present in the associated HomeConfig.factoryRegistry union'ed with those already known to the extended sub-class (e.g specific DeviceType that is aware of the set of TraitFactorys specified in its type definition).

Inherited properties

abstract Collection<Trait>

This property is deprecated. This member is deprecated please use the traits() API.

Public constructors

RootNodeDevice

RootNodeDevice(
    metadata: DeviceType.Metadata,
    traitProvider: TraitProvider,
    eventProvider: HasEvents,
    standardTraits: RootNodeDevice.StandardTraits
)

Creates the RootNodeDevice class.

Public properties

factory

open val factoryDeviceTypeFactory<RootNodeDevice>

metadata

open val metadataDeviceType.Metadata