A collection of actions that you trigger as a group.


class HMActionSet : NSObject


Action sets can be executed as a result of evaluating a trigger (instances of HMTrigger) or manually with executeActionSet(_:completionHandler:). Actions in an action set are performed in an unspecified order. You create new action sets using the addActionSet(withName:completionHandler:) method of HMHome.


Identifiying an Action Set

var uniqueIdentifier: UUID

The action set's unique identifier.

var name: String

The name of the action set.

Specifying a Type

var actionSetType: String

The type of the action set, such as built-in or user-defined.

Action Set Types

The types of action sets that you can define.

Defining the Associated Actions

var actions: Set<HMAction>

Set of actions in the action set.

class HMCharacteristicWriteAction

An action in an action set that writes a value to a characteristic.

class HMAction

An abstract base class for actions in HomeKit.

Keeping Track of Execution

var isExecuting: Bool

The execution status of the action set.

var lastExecutionDate: Date?

The last execution date of the action set.


Inherits From

Conforms To

See Also

Action Sets

class HMTimerTrigger

A trigger to activate an action set based on a periodic timer.

class HMEventTrigger

A trigger to activate an action set based on a set of events and optional conditions.