Starter

class Starter : Node, HasOutput


Defines the initial triggers that activate an automation, such as a change to a trait.

Either trait or event must be set.

Summary

Public constructors

Starter(
    entity: HasId,
    deviceType: DeviceTypeFactory<DeviceType>?,
    trait: TraitFactory<Trait>,
    output: String
)

Create a Starter instance from an entity, a DeviceType, and a Trait.

Starter(
    entity: HasId,
    deviceType: DeviceTypeFactory<DeviceType>?,
    event: EventFactory<Event>,
    parameters: List<Parameter>,
    output: String
)

Create a Starter from an entity, a DeviceType, and an Event.

Public properties

DeviceTypeFactory<DeviceType>?

The device type associated with this Starter.

HasId

The unique ID for the entity associated with the Starter.

EventFactory<Event>?

The Event associated with this Starter.

open String

The output.

List<Parameter>

The Parameters for the Event associated with this Starter.

TraitFactory<Trait>?

The Trait associated with this Starter.

String

The ID for the Trait associated with this Starter.

Inherited properties

String?

String identifier of this node.

Public constructors

Starter

Starter(
    entity: HasId,
    deviceType: DeviceTypeFactory<DeviceType>? = null,
    trait: TraitFactory<Trait>,
    output: String
)

Create a Starter instance from an entity, a DeviceType, and a Trait. An entity may be a Device or a Structure.

Parameters
entity: HasId

The unique ID for the entity associated with the Starter.

deviceType: DeviceTypeFactory<DeviceType>? = null

The device type associated with this Starter.

trait: TraitFactory<Trait>

The Trait associated with this Starter.

output: String

The output.

Starter

Starter(
    entity: HasId,
    deviceType: DeviceTypeFactory<DeviceType>? = null,
    event: EventFactory<Event>,
    parameters: List<Parameter> = emptyList(),
    output: String
)

Create a Starter from an entity, a DeviceType, and an Event. An entity may be a Device or a Structure.

Parameters
entity: HasId

The unique ID for the entity associated with the Starter.

deviceType: DeviceTypeFactory<DeviceType>? = null

The device type associated with this Starter. If the entity is a Structure, this is set to null.

event: EventFactory<Event>

The Event associated with this Starter.

parameters: List<Parameter> = emptyList()

The parameters for the Event associated with this Starter. If no Event is associated with this Starter, parameters is set to null.

output: String

The output.

Public properties

deviceType

val deviceTypeDeviceTypeFactory<DeviceType>?

The device type associated with this Starter.

entity

val entityHasId

The unique ID for the entity associated with the Starter.

event

val eventEventFactory<Event>?

The Event associated with this Starter.

output

open val outputString

The output.

parameters

val parametersList<Parameter>

The Parameters for the Event associated with this Starter.

trait

val traitTraitFactory<Trait>?

The Trait associated with this Starter.

traitId

val traitIdString

The ID for the Trait associated with this Starter.