StateReaderNodeDsl

interface StateReaderNodeDsl : AutomationFlowContributor

Known direct subclasses
ParallelFlowBuilder

Type-safe builder that builds a ParallelFlow node.

SequentialFlowBuilder

Type-safe builder that builds a SequentialFlow Node.


Interface for constructing StateReader nodes and contributing them to an automation flow.

Summary

Public functions

open TypedExpression<T>
<T : Trait> stateReader(structure: Structure, trait: TraitFactory<T>)

Build a StateReader.

open TypedExpression<T>
<T : Trait> stateReader(
    device: HomeDevice,
    deviceType: DeviceTypeFactory<DeviceType>,
    trait: TraitFactory<T>
)

Build a StateReader.

open TypedExpression<T>
<T : Trait> stateReader(
    unknownEntity: UnknownEntity,
    entityType: TypeFactory<HomeObjectType>,
    trait: TraitFactory<T>
)

Build a StateReader using an UnknownEntity.

Public functions

stateReader

open fun <T : Trait> stateReader(structure: Structure, trait: TraitFactory<T>): TypedExpression<T>

Build a StateReader.

Parameters
structure: Structure

The Structure associated with the StateReader.

trait: TraitFactory<T>

The Trait associated with the StateReader.

Returns
TypedExpression<T>

A StateReader instance.

stateReader

open fun <T : Trait> stateReader(
    device: HomeDevice,
    deviceType: DeviceTypeFactory<DeviceType>,
    trait: TraitFactory<T>
): TypedExpression<T>

Build a StateReader.

Parameters
device: HomeDevice

The Device associated with the StateReader.

deviceType: DeviceTypeFactory<DeviceType>

The DeviceType associated with the StateReader.

trait: TraitFactory<T>

The Trait associated with the StateReader.

Returns
TypedExpression<T>

A StateReader instance.

stateReader

open fun <T : Trait> stateReader(
    unknownEntity: UnknownEntity,
    entityType: TypeFactory<HomeObjectType>,
    trait: TraitFactory<T>
): TypedExpression<T>

Build a StateReader using an UnknownEntity. Automations created using this method will not be valid. This method can be used to create draft automations.

Parameters
unknownEntity: UnknownEntity

The UnknownEntity associated with the StateReader.

entityType: TypeFactory<HomeObjectType>

The type associated with the Starter.

trait: TraitFactory<T>

The Trait associated with the StateReader.

Returns
TypedExpression<T>

A StateReader instance.