The following declarations are provided by module GoogleHomeSDK.
-
A type-erased
BitmapDeclaration
Swift
struct AnyBitmapextension AnyBitmap : AutomationValue, Bitmap, Equatable, ExpressibleByArrayLiteral, Hashable, OptionSet, RawRepresentable, Sendable, SetAlgebra -
A type-erased
EnumDeclaration
Swift
struct AnyEnumextension AnyEnum : AutomationValue, Enum, Equatable, Hashable, RawRepresentable, Sendable -
Struct holding information about a generic, encoded event that has yet to be parsed into its corresponding concrete type.
Declaration
Swift
struct AnyEventextension AnyEvent : Sendable -
A type-erased
StructDataRepresentableDeclaration
Swift
struct AnyStructextension AnyStruct : AutomationValue, Equatable, Hashable, Sendable, StructDataRepresentable -
Undocumented
Declaration
Swift
enum AnyAutomationEntityextension AnyAutomationEntity : AutomationValue, Copyable, Equatable, Equatable, Escapable, Hashable, Hashable, Sendable, Sendable -
Represents a constant value in the automation graph.
Declaration
Swift
enum AnyAutomationValueextension AnyAutomationValue : Equatable, Hashable, Sendable -
Supported automation value types.
Declaration
Swift
protocol AutomationValue : Hashable, Sendable -
Undocumented
Declaration
Swift
struct AutomationEntryextension AutomationEntry : AutomationValue, Equatable, Hashable, Sendable -
Array of automation values.
Declaration
Swift
protocol AutomationValueArray : Collection where Self.Element : AutomationValue -
Optional array of automation values.
Declaration
Swift
protocol OptionalAutomationValueArray -
Optional-wrapped automation value.
Declaration
Swift
protocol OptionalAutomationValue -
Optional-wrapped comparable type.
Declaration
Swift
protocol OptionalComparable -
Optional-wrapped numeric type.
Declaration
Swift
protocol OptionalNumeric -
Optional-wrapped signed integer type.
Declaration
Swift
protocol OptionalSignedInteger -
Optional-wrapped unsigned integer type.
Declaration
Swift
protocol OptionalUnsignedInteger -
Undocumented
Declaration
Swift
struct AnyNodeCandidateextension AnyNodeCandidate : Equatable, Hashable, Sendable -
Details about an attribute field.
Declaration
Swift
struct AttributeFieldDetailsextension AttributeFieldDetails : Equatable, FieldDetails, Hashable, Sendable -
A base protocol for all Automation instances.
Declaration
Swift
protocol BaseAutomation : Identifiable, Sendable -
User-specifiable fields of the
Automation. Used primarily for automation creation.Declaration
Swift
typealias DraftAutomation = BaseAutomation -
The main representation of an automation, containing Metadata fields as well as the Automation Graph containing Automation nodes, including Starter instances, Condition instances, Action instances, and more.
Declaration
Swift
protocol Automation : BaseAutomation -
Undocumented
Declaration
Swift
final class MutableAutomationData -
A base protocol representing a ‘node’ for the automation graph. All parts of the automation graph must conform to the Node protocol.
Declaration
Swift
protocol Node : Hashable, Identifiable, Sendable where Self.ID == Stringextension Node : Equatable -
A base protocol for all ‘Flow’ Nodes.
Declaration
Swift
protocol Flow : Node -
A starter that allows the user to manually activate an automation.
Declaration
Swift
struct ManualStarterextension ManualStarter : Equatable, Hashable, Identifiable, Node, Sendable -
A Node that will delay execution for a specified length of time.
Declaration
-
A Node that will terminates execution of all the following nodes if the automation is triggered again within the specified time range.
Declaration
-
Base protocol for all Starters in the automation graph.
Declaration
Swift
protocol Starter : NodeWithOutput -
Struct for all Event based starters, relying on an event to trigger the automation.
Declaration
Swift
struct EventStarterextension EventStarter : Copyable, CustomStringConvertible, Equatable, Escapable, Hashable, Identifiable, Node, NodeWithOutput, Sendable, Starter -
Struct for all Attribute based starters relying on the value of a trait.
Declaration
Swift
struct AttributeStarterextension AttributeStarter : Copyable, CustomStringConvertible, Equatable, Escapable, Hashable, Identifiable, Node, NodeWithOutput, Sendable, Starter -
Base struct for all Conditions in the automation graph.
Declaration
Swift
struct Conditionextension Condition : Copyable, Equatable, Escapable, Hashable, Identifiable, Node, Sendable -
Base struct for all Actions in the automation graph.
Declaration
Swift
struct Actionextension Action : Copyable, CustomStringConvertible, Equatable, Escapable, Hashable, Identifiable, Node, Sendable -
Represents the behavior of an action.
Declaration
Swift
protocol ActionBehavior : Sendable -
A trait command used in an automation action.
Declaration
Swift
struct AutomationCommandextension AutomationCommand : ActionBehavior, Copyable, Copyable, CustomStringConvertible, Equatable, Escapable, Escapable, Sendable -
Trait attribute update used in an automation action.
Declaration
Swift
struct Updateextension Update : ActionBehavior, Copyable, Copyable, CustomStringConvertible, Equatable, Escapable, Escapable, Sendable -
A class that accesses a trait’s state, used for conditions.
Declaration
Swift
struct StateReaderextension StateReader : Equatable, Hashable, Identifiable, Node, NodeWithOutput, Sendable -
A protocol that specifies when a node that can produce output, such as Starter or StateReader.
Declaration
Swift
protocol NodeWithOutput : Node -
A Parameter contains the identifier and value of a parameter for a starter, command, or event.
Declaration
Swift
struct Parameterextension Parameter : Equatable, Hashable, Sendable -
Enum to define the ways of coordinating the execution of multiple concurrent operations in a ParallelFlow.
Declaration
Swift
enum JoinSemanticTypeextension JoinSemanticType : Equatable, Hashable, Sendable -
Struct that represents the assignment of a value to a variable.
Declaration
Swift
struct Assignmentextension Assignment : Equatable, Hashable, Identifiable, Node, NodeWithOutput, Sendable -
automation(id:structureID:name:description:isActive:firstPartyClientMetadata:clientFeatureGroup:maxExecutionCount:_:)
Build an automation.
Declaration
Swift
func automation(id: String = "", structureID: String = "", name: String = "", description: String = "UNSPECIFIED_DESCRIPTION", isActive: Bool = true, firstPartyClientMetadata: Data? = nil, clientFeatureGroup: String? = nil, maxExecutionCount: Int32? = nil, @FlowBuilder _ sequentialNodes: () -> [any Node]) -> any DraftAutomationParameters
idThe ID of the automation. Defaults to empty string. If empty, the automation will be considered as a new automation.
structureIDThe structure ID of the automation. Defaults to empty string. If empty, will be populated with the structure ID of the current structure on create/update.
nameThe name of the automation, must be specified and not empty.
descriptionThe description of the automation.
isActiveWhether the automation is active; defaults to true.
firstPartyClientMetadataThe first party client metadata of the automation.
clientFeatureGroupThe client feature group of the automation.
maxExecutionCountThe maximum number of times the automation can be executed. Defaults to nil if not set.
-
Build an automation.
Declaration
Swift
func automation(id: String = "", structureID: String = "", name: String = "", description: String = "UNSPECIFIED_DESCRIPTION", isActive: Bool = true, maxExecutionCount: Int32? = nil, @FlowBuilder _ sequentialNodes: () -> [any Node]) -> any DraftAutomationParameters
idThe ID of the automation. Defaults to empty string. If empty, the automation will be considered as a new automation.
structureIDThe structure ID of the automation. Defaults to empty string. If empty, will be populated with the structure ID of the current structure on create/update.
nameThe name of the automation, must be specified and not empty.
descriptionThe description of the automation.
isActiveWhether the automation is active; defaults to true.
maxExecutionCountThe maximum number of times the automation can be executed. Defaults to nil if not set.
-
Build a
SequentialFlowfrom aFlowBuilder.Declaration
Swift
func sequential(@FlowBuilder _ nodes: () -> [any Node]) -> SequentialFlow -
Build a
ParallelFlowfrom aFlowBuilder.Declaration
Swift
func parallel(@FlowBuilder _ nodes: () -> [any Node]) -> ParallelFlow -
Build a
SelectFlowfrom aFlowBuilder.Declaration
Swift
func select(@FlowBuilder _ nodes: () -> [any Node]) -> SelectFlow -
Creates a
TypedReferenceto a device-basedAttributeStarterfrom the givendevice,deviceType, andtrait.The
TypedReferencecan be provided to aFlowBuilderto add the underlyingAttributeStarterto a flow and used to select the field to read from the corresponding trait.Declaration
Swift
func starter<T>(_ device: HomeDevice, _ deviceType: any DeviceType.Type, _ trait: T.Type) -> TypedReference<T, AttributeStarter> where T : Trait -
Creates a
TypedReferenceto an expression-basedAttributeStarter.The
TypedReferencecan be provided to aFlowBuilderto add the underlyingAttributeStarterto a flow and used to select the field to read from the corresponding trait.Declaration
Swift
func starter<T>(_ entityExpression: TypedExpression<AnyAutomationEntity>, _ trait: T.Type) -> TypedReference<T, AttributeStarter> where T : Trait -
Creates a
TypedReferenceto a list-returning expression-basedAttributeStarter.The
TypedReferencecan be provided to aFlowBuilderto add the underlyingAttributeStarterto a flow and used to select the field to read from the corresponding trait.Declaration
Swift
func starter<T>(_ entityExpression: TypedExpression<[AnyAutomationEntity]>, _ trait: T.Type) -> TypedReference<T, AttributeStarter> where T : Trait -
Creates a
TypedReferenceto a structure-basedAttributeStarterfrom the givenstructureandtrait.The
TypedReferencecan be provided to aFlowBuilderto add the underlyingAttributeStarterto a flow and used to select the field to read from the corresponding trait.Declaration
Swift
func starter<T>(_ structure: Structure, _ trait: T.Type) -> TypedReference<T, AttributeStarter> where T : Trait -
Creates a device-based
EventStarterfrom the givendevice,deviceType, andevent.Declaration
Swift
func starter<T>(_ device: HomeDevice, _ deviceType: any DeviceType.Type, _ event: T.Type) -> TypedReference<T, EventStarter> where T : Event -
Creates a
TypedReferenceto a expression-basedEventStarter.Declaration
Swift
func starter<T>(_ entityExpression: TypedExpression<AnyAutomationEntity>, _ event: T.Type) -> TypedReference<T, EventStarter> where T : Event -
Creates a structure-based
EventStarterfrom the givenstructureandevent.Declaration
Swift
func starter<T>(_ structure: Structure, _ event: T.Type) -> TypedReference<T, EventStarter> where T : Event -
Creates a device-based
EventStarterfrom the givendevice,deviceType,event, andparameters.Declaration
Swift
func starter<T>(_ device: HomeDevice, _ deviceType: any DeviceType.Type, _ event: T.Type, @ParameterBuilder<T> _ parameters: () -> [Parameter]) -> TypedReference<T, EventStarter> where T : Event -
Creates a
TypedReferenceto a expression-basedEventStarterwith the givenparameters.Declaration
Swift
func starter<T>(_ entityExpression: TypedExpression<AnyAutomationEntity>, _ event: T.Type, @ParameterBuilder<T> _ parameters: () -> [Parameter]) -> TypedReference<T, EventStarter> where T : Event -
Creates a structure-based
EventStarterfrom the givenstructure,event, andparameters.Declaration
Swift
func starter<T>(_ structure: Structure, _ event: T.Type, @ParameterBuilder<T> _ parameters: () -> [Parameter]) -> TypedReference<T, EventStarter> where T : Event -
Creates a
TypedReferenceto a device-basedStateReaderfrom the givendevice,deviceType, andtrait.The
TypedReferencecan be provided to aFlowBuilderto add the underlyingStateReaderto a flow and used to select the field to read from the corresponding trait.Declaration
Swift
func stateReader<T>(_ device: HomeDevice, _ deviceType: any DeviceType.Type, _ trait: T.Type) -> TypedReference<T, StateReader> where T : Trait -
Creates a
TypedReferenceto an expression-basedStateReaderfrom the givenexpression, andtrait.The
TypedReferencecan be provided to aFlowBuilderto add the underlyingStateReaderto a flow and used to select the field to read from the corresponding trait.Declaration
Swift
func stateReader<T>(_ entityExpression: TypedExpression<AnyAutomationEntity>, _ trait: T.Type) -> TypedReference<T, StateReader> where T : Trait -
Creates a
TypedReferenceto an expression-basedStateReaderfrom the givenexpression, andtrait.The
TypedReferencecan be provided to aFlowBuilderto add the underlyingStateReaderto a flow and used to select the field to read from the corresponding trait.Declaration
Swift
func stateReader<T>(_ entityExpression: TypedExpression<[AnyAutomationEntity]>, _ trait: T.Type) -> TypedReference<T, StateReader> where T : Trait -
Creates a
TypedReferenceto a structure-basedStateReaderfrom the givenstructureandtrait.The
TypedReferencecan be provided to aFlowBuilderto add the underlyingStateReaderto a flow and used to select the field to read from the corresponding trait.Declaration
Swift
func stateReader<T>(_ structure: Structure, _ trait: T.Type) -> TypedReference<T, StateReader> where T : Trait -
Creates a
TypedReferenceto a structure-basedAssignmentwith givenTrait. TheTypedReferencecan be provided to aFlowBuilderto add the underlyingAssignmentto a flow and used to assign expression to the corresponding trait.UnknownExpressionwith empty Data() is assigned by default. In order to assign expression or value, call ‘.assign’ to already created TypedReferenceDeclaration
Swift
func variable<T>() -> TypedReference<T, Assignment> -
Creates a condition.
Declaration
Swift
func condition(for duration: Duration? = nil, _ expression: () -> TypedExpression<Bool>) -> ConditionParameters
expressionBuilder for the boolean
TypedExpressionof the condition.Return Value
The
Conditionnode. -
Internal API exposed for codegen. Do NOT use.
Declaration
Swift
func fieldSelect<T, N, V>(from selectFrom: TypedReference<T, N>, selectedField: any Field) -> TypedExpression<V> where N : NodeWithOutput, V : AutomationValue -
Internal API exposed for codegen. Do NOT use.
Declaration
Swift
func fieldSelect<V>(from selectFrom: any Expression, selectedField: any Field) -> TypedExpression<V> where V : AutomationValue -
Build a
ManualStarternode.Declaration
Swift
func manualStarter() -> ManualStarter -
Build a
Suppressionnode with the givenduration.Declaration
Swift
func suppress(for duration: Duration) -> Suppression -
Build a device-based action with the given
device,deviceType, andbehavior.Declaration
Swift
func action(_ device: HomeDevice, _ deviceType: any DeviceType.Type, _ behavior: () -> any ActionBehavior) -> Action -
Build an expression-based action with the given
expressionandbehavior.Declaration
Swift
func action(_ entityExpression: TypedExpression<AnyAutomationEntity>, _ behavior: () -> any ActionBehavior) -> Action -
Build an expression-based action with the given list-based
expressionandbehavior.Declaration
Swift
func action(_ entityExpression: TypedExpression<[AnyAutomationEntity]>, _ behavior: () -> any ActionBehavior) -> Action -
Build a structure-based action with the given
structureandbehavior.Declaration
Swift
func action(_ structure: Structure, _ behavior: () -> any ActionBehavior) -> Action -
A builder for Trait attribute updates.
Methods will be surfaced, based on the associated Trait, to allow setting the writable attributes.
Declaration
Swift
final class Updater<T> where T : Trait -
A result builder that builds a list of nodes for a flow.
Declaration
Swift
@resultBuilder struct FlowBuilder -
A typed reference to a NodeWithOutput(Starter, StateReader or Assignment)
Declaration
-
Undocumented
Declaration
Swift
struct TypedParameter<Container> -
Undocumented
Declaration
Swift
@resultBuilder struct ParameterBuilder<Container> -
A protocol for handling Automation objects. This protocol will support the various CRUD operations that can be performed on an automation including lifecycle and management.
Declaration
Swift
@MainActor protocol AutomationManager : Sendable -
Validation issues that makes the automation invalid. A valid automation should have the following properties:
- Semantic correctness: The automation graph should follow some rules in order to be executed as expected,
- Valid expression tree : The expression should be compilable and evalable.
- Prevent abuse: Automation Platform Abuse Prevention. All operations should be supported by the entity capabilities.
Declaration
Swift
struct AutomationValidationIssueextension AutomationValidationIssue : Equatable, Sendable -
The ID of a behavior, which can be a command, event or trait.
Declaration
Swift
enum BehaviorIDextension BehaviorID : Equatable, Sendable -
The identifier of a matter attribute.
Declaration
Swift
enum AttributeIDextension AttributeID : Equatable, Sendable -
The severity of the validation issue.
Declaration
Swift
enum ValidationIssueSeverityextension ValidationIssueSeverity : Equatable, Hashable, Sendable -
The possible validation issues that may occur.
Declaration
Swift
enum ValidationIssueTypeextension ValidationIssueType : Equatable, Sendable -
The output variable has been defined in multiple nodes with different types.
Declaration
Swift
struct OutputTypeMismatchextension OutputTypeMismatch : Equatable, Sendable -
The output variable has been reinitialized in multiple nodes.
Declaration
Swift
struct OutputReinitializedextension OutputReinitialized : Equatable, Sendable -
The expression contains an invalid number of arguments.
Declaration
Swift
struct InvalidArgumentCountextension InvalidArgumentCount : Equatable, Sendable -
The expression uses an invalid operand.
Declaration
Swift
struct InvalidOperandextension InvalidOperand : Equatable, Sendable -
The arguments for the operator are not valid.
Declaration
Swift
struct InvalidArgumentsForOperatorextension InvalidArgumentsForOperator : Equatable, Sendable -
The condition type is not valid.
Declaration
Swift
struct InvalidConditionTypeextension InvalidConditionType : Equatable, Sendable -
The duration expression type is not valid.
Declaration
Swift
struct InvalidDurationExpressionTypeextension InvalidDurationExpressionType : Equatable, Sendable -
The entity expression type is not valid.
Declaration
Swift
struct InvalidEntityExpressionTypeextension InvalidEntityExpressionType : Equatable, Sendable -
The
FIELD_SELECTexpression uses an invalid field.Declaration
Swift
struct InvalidFieldextension InvalidField : Equatable, Sendable -
The “reference,” which refers to output produced by a preceding node, is unknown.
Declaration
Swift
struct InvalidReferenceextension InvalidReference : Equatable, Sendable -
Reasons why a candidate node is not supported.
Declaration
Swift
struct UnsupportedCandidateReasonextension UnsupportedCandidateReason : Equatable, Hashable, Sendable -
The type of presence sensing setup that is missing.
Declaration
Swift
enum PresenceSensingSetupTypeextension PresenceSensingSetupType : Equatable, Hashable, Sendable -
The reason why a candidate is not supported.
Declaration
Swift
enum UnsupportedCandidateReasonTypeextension UnsupportedCandidateReasonType : Equatable, Hashable, Sendable -
Undocumented
Declaration
Swift
enum InvalidEntityReasonTypeextension InvalidEntityReasonType : Equatable, Hashable, Sendable -
Represents automation candidate nodes corresponding to a command. These can be used in actions.
Declaration
Swift
struct CommandCandidateextension CommandCandidate : ActionCandidate, Copyable, Equatable, Equatable, Escapable, Hashable, Hashable, NodeCandidate, NodeCandidate, Sendable, Sendable -
Details about a command field.
Declaration
Swift
struct CommandFieldDetailsextension CommandFieldDetails : Equatable, FieldDetails, Hashable, Sendable -
Constraints on a trait attribute, command parameter or event field. Represents the possible values that an attribute, parameter or field can have.
Declaration
Swift
enum Constraintextension Constraint : Equatable, Hashable, Sendable -
Represents a group of bits in a bitmap - with start and end positions along with a name.
This is an EXPERIMENTAL feature that may be removed or changed without notice.
Declaration
Swift
struct CombinedBitsDescriptorextension CombinedBitsDescriptor : Equatable, Hashable, Sendable -
Constraint for fields of the struct.
Declaration
Swift
struct StructFieldConstraintextension StructFieldConstraint : Equatable, Hashable, Sendable -
Represents the base unit of a measurement.
Declaration
Swift
enum BaseUnitextension BaseUnit : Equatable, Hashable, RawRepresentable, Sendable -
Represents a unit of measurement which consists of a base unit and a scale.
For example, if a field has the unit centi-celsius, the base unit would be Celsius and the multiplier would be 0.01.
Declaration
Swift
struct ConstraintUnitextension ConstraintUnit : Equatable, Hashable, Sendable -
Manages Discovery Candidates for all Structures in a User Account.
This protocol is used to manage the Discovery Candidates for all Structures in a User Account. This includes fetching, caching and freshing the candidates.
Note
This protocol exists to facilitate eventual SRL migration.Declaration
Swift
protocol DiscoveryController : Sendable -
Undocumented
Declaration
Swift
enum EntityTypeextension EntityType : AutomationValue, Copyable, Equatable, Equatable, Escapable, Hashable, Hashable, Sendable, Sendable -
Represents automation candidate nodes corresponding to an event. These can be used in starters.
Declaration
Swift
struct EventCandidateextension EventCandidate : Copyable, Equatable, Equatable, Escapable, Hashable, Hashable, NodeCandidate, NodeCandidate, Sendable, Sendable, StarterCandidate -
Details about an event field.
Declaration
Swift
struct EventFieldDetailsextension EventFieldDetails : Equatable, FieldDetails, Hashable, Sendable -
An expression which evaluates to a value.
Depending on the concrete type, it may represent:
- Simple literal expressions including a constant or a reference.
- Complex expressions with one operator and one or more operand(s), such as a logical expression, a comparison expression, a struct traversal expression.
Declaration
Swift
protocol Expression : Sendable -
Typed-erased Expression.
Declaration
-
Represent a complex expression with one operator and one or more operand(s).
Depending on the operator type, it may represent:
- Arithmetic (plus, minus, etc.) expressions,
- Comparison (equals, greaterThan, etc.) expressions,
- Logical (and, or, etc.) expressions,
- Struct traversal (fieldSelect) expressions,
- List accessor (listSize, listContains, etc.) expressions,
- Comprehension (listAnyMatch, listFilter, etc.) expressions.
Declaration
Swift
protocol IdentifiableExpression : Expression, Identifiable where Self.ID == String -
Represent a binary expression with two operands.
The full expression is represented as:
operand1operatoroperand2.Declaration
Swift
protocol BinaryExpression : IdentifiableExpression -
Represent a ternary expression with three operands.
Declaration
Swift
protocol TernaryExpression : IdentifiableExpression -
Represent a unary expression with one operand.
The full expression is represented as:
operatoroperand.Declaration
Swift
protocol UnaryExpression : IdentifiableExpression -
Represents a constant.
Constant is often used as the second operand in expressions. For instance: Equals(operand1: Reference() , operand2: Constant(true)).
Declaration
-
Represent a reference, to the previously defined node in the automation graph.
Reference is often used as the first operand in expressions. for instance: Equals(operand1: Reference() , operand2: Constant(true)).
Declaration
-
Represents a reference declaration. Only valid in a list comprehension expression.
Declaration
-
The plus operator, which evaluates to
operand1+operand2.Declaration
Swift
struct Plusextension Plus : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The minus operator, which evaluates to
operand1-operand2.Declaration
Swift
struct Minusextension Minus : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The multiply operator, which evaluates to
operand1*operand2.Declaration
Swift
struct Multiplyextension Multiply : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The divide operator, which evaluates to
operand1/operand2.Declaration
Swift
struct Divideextension Divide : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The equality operator, which evaluates to
truewhenoperand1equalsoperand2.Declaration
Swift
struct Equalsextension Equals : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The equality operator, which evaluates to
truewhenoperand1not equals tooperand2.Declaration
Swift
struct NotEqualsextension NotEquals : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The between operator, which evaluates to
truewhenoperand1is betweenoperand2andoperand3.Declaration
Swift
struct Betweenextension Between : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable, TernaryExpression -
The between times operator, which evaluates to
truewhenoperand1is betweenoperand2andoperand3.NOTE: Only valid for
TimeOfDay-based expressions.Declaration
Swift
struct BetweenTimesextension BetweenTimes : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable, TernaryExpression -
The comparison operator, which evaluates to
truewhenoperand1>operand2.Declaration
Swift
struct GreaterThanextension GreaterThan : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The comparison operator, which evaluates to
truewhenoperand1<operand2.Declaration
Swift
struct LessThanextension LessThan : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The comparison operator, which evaluates to
truewhenoperand1>=operand2.Declaration
Swift
struct GreaterThanOrEqualsextension GreaterThanOrEquals : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The comparison operator, which evaluates to
truewhenoperand1>=operand2.Declaration
Swift
struct LessThanOrEqualsextension LessThanOrEquals : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Selects an attribute, an event field or struct field(s) from a reference expression.
Declaration
Swift
struct FieldSelectextension FieldSelect : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The logical AND operator which evaluates to
truewhen bothoperand1andoperand2aretrue.Declaration
Swift
struct Andextension And : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The logical OR operator which evaluates to
truewhen eitheroperand1oroperand2istrue.Declaration
Swift
struct Orextension Or : BinaryExpression, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
The logical NOT operator which evaluates to
truewhenoperandisfalse.Declaration
Swift
struct Notextension Not : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable, UnaryExpression -
Represents the “size” operation on a list expression.
Declaration
Swift
struct ListSizeextension ListSize : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “in” operation on a list expression. Returns
trueif the element is in the list.Declaration
Swift
struct ListInextension ListIn : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “contains” operation on a list expression. Returns
trueif the element is in the list.Declaration
Swift
struct ListContainsextension ListContains : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “get” operation on a list expression. Returns the element at the given index.
Declaration
Swift
struct ListGetextension ListGet : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents list comprehension expressions.
Declaration
Swift
protocol Comprehension : IdentifiableExpression -
Represents the “all match” operation on a list expression.
Declaration
Swift
struct ListAllMatchextension ListAllMatch : Comprehension, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “any match” operation on a list expression.
Declaration
Swift
struct ListAnyMatchextension ListAnyMatch : Comprehension, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “none match” operation on a list expression.
Declaration
Swift
struct ListNoneMatchextension ListNoneMatch : Comprehension, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the map operation on a list expression.
Declaration
Swift
struct ListMapextension ListMap : Comprehension, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “filter” operation on a list expression.
Declaration
Swift
struct ListFilterextension ListFilter : Comprehension, Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “keys” operation on a map expression.
Declaration
Swift
struct MapKeysextension MapKeys : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “values” operation on a map expression.
Declaration
Swift
struct MapValuesextension MapValues : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “size” operation on a map expression.
Declaration
Swift
struct MapSizeextension MapSize : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “filter” operation on a map expression. Returns a new map with the filtered entries.
Declaration
Swift
struct MapFilterextension MapFilter : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Represents the “get devices of type” operation on a structure or room.
Declaration
Swift
struct GetDevicesOfTypeextension GetDevicesOfType : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Undocumented
Declaration
Swift
struct UnknownExpressionextension UnknownExpression : Equatable, Expression, Identifiable, IdentifiableExpression, Sendable -
Undocumented
Declaration
Swift
func constant(_ timeOfDay: TimeOfDay) -> TypedExpression<TimeOfDay> -
Undocumented
Declaration
Swift
func constant(_ duration: Duration) -> TypedExpression<Duration> -
Basic information about a Trait field.
Declaration
Swift
protocol FieldDetails : Hashable -
Represents a date.
This struct doesn’t include any time zone related information.
Declaration
Swift
struct LocalDateextension LocalDate : AutomationValue, Comparable, Copyable, Copyable, Decodable, Encodable, Equatable, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Sendable, Sendable -
Represents month and day.
This struct doesn’t include any time zone related information.
Declaration
Swift
struct MonthDayextension MonthDay : AutomationValue, Copyable, Decodable, Encodable, Equatable, Equatable, Escapable, Hashable, Hashable, Sendable, Sendable, StructDataRepresentable -
Defines the common attributes of all Automations Discovery candidates.
Declaration
Swift
protocol NodeCandidate : Hashable, Sendable -
Defines the common attributes of all Automations Discovery candidates that can be converted to a Starter.
Declaration
Swift
protocol StarterCandidate : NodeCandidate -
Defines the common attributes of all Automations Discovery candidates that can be converted to a StateReader.
Declaration
Swift
protocol StateReaderCandidate : NodeCandidate -
Defines the common attributes of all Automations Discovery candidates that can be converted to an Action.
Declaration
Swift
protocol ActionCandidate : NodeCandidate -
The time of a daily solar event such as sunrise, noon, and sunset.
Declaration
Swift
struct SolarTimeextension SolarTime : AutomationValue, Copyable, Decodable, Encodable, Equatable, Equatable, Escapable, Hashable, Hashable, Sendable, Sendable, StructDataRepresentable -
Represents a time of day. The date and time zone are either not significant or are specified elsewhere.
Declaration
Swift
struct TimeOfDayextension TimeOfDay : AutomationValue, Copyable, Decodable, Encodable, Equatable, Equatable, Escapable, Hashable, Hashable, Sendable, Sendable, StructDataRepresentable -
Represents automation candidate nodes corresponding to a trait’s attributes. These can be used in starters, state readers and actions.
Declaration
Swift
struct TraitAttributesCandidateextension TraitAttributesCandidate : ActionCandidate, Copyable, Copyable, Copyable, Equatable, Equatable, Equatable, Equatable, Escapable, Escapable, Escapable, Hashable, Hashable, Hashable, Hashable, NodeCandidate, NodeCandidate, NodeCandidate, NodeCandidate, Sendable, Sendable, Sendable, Sendable, StarterCandidate, StateReaderCandidate -
Wraps an
Expressionwith an associated value type.Declaration
-
Represents an unknown node in the automation graph.
Declaration
-
Represents year and month.
This struct doesn’t include any time zone related information.
Declaration
Swift
struct YearMonthextension YearMonth : AutomationValue, Comparable, Copyable, Copyable, Decodable, Encodable, Equatable, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Sendable, Sendable, StructDataRepresentable -
A structure that holds all the necessary parameters to send a command.
Declaration
Swift
struct BatchCommandRequestInfoextension BatchCommandRequestInfo : Sendable -
Represents a command that can be batched with other commands. It captures the request info and a closure to transform the response. ResponseType can be any type, including Void. It is typically a subtype of CommandResponse.
Declaration
Swift
struct BatchableCommand<ResponseType>extension BatchableCommand : Sendable -
Basic interface for Trait commands.
Declaration
Swift
protocol Command : Sendable -
A class that batches commands and sends them. It serves as both a proxy and a transaction holder.
Declaration
Swift
class CommandBatcher -
Suggested user actions to potentially resolve a commissioning failure.
Declaration
Swift
enum MatterSuggestedUserActionextension MatterSuggestedUserAction : CaseIterable, Equatable, Hashable, RawRepresentable, Sendable -
The result of a failed Matter Commissioning attempt.
Declaration
Swift
struct MatterUnsuccessfulCommissioningResultextension MatterUnsuccessfulCommissioningResult : Sendable -
Publicly-visible Configuration for GoogleHomeSDK.
Declaration
Swift
@MainActor struct HomeClientConfigurationextension HomeClientConfiguration : Sendable -
The list of traits and device types to be used by the Automations SDK.
Declaration
Swift
@MainActor final class ReferencedAutomationTypesextension ReferencedAutomationTypes : Sendable -
Undocumented
Declaration
Swift
enum ConnectivityStateextension ConnectivityState : Equatable, Hashable, Sendable -
Protocol implemented by all the generated
DeviceTypestructs.A device type represents a collection of traits with connected functionality.
Declaration
Swift
protocol DeviceType : CustomDebugStringConvertible, Hashable, Sendableextension DeviceType : Equatable -
A collection of already fetched
DeviceTypedata.Provides subscript access to
DeviceTypes by their types.Declaration
Swift
final class DeviceTypeCollectionextension DeviceTypeCollection : Copyable, Equatable, Escapable, Hashable, Sendable -
Controller to access concrete
DeviceTypes for aHomeDevice.Declaration
Swift
final class DeviceTypeControllerextension DeviceTypeController : Sendable -
Additional information about a device type.
Declaration
Swift
struct DeviceTypeMetadataextension DeviceTypeMetadata : Equatable, Hashable, Sendable -
Basic interface for Trait events.
Events contain a record of past state transitions and other data that cannot easily be modeled by attributes.
Declaration
Swift
protocol Event : CustomDebugStringConvertible, Sendable -
Controller for subscribing to events from a particular object.
Declaration
Swift
protocol EventController : Sendable -
The reported importance level of an
Event.These correspond to Matter event priority levels, with some additional levels providing extra granularity.
Declaration
Swift
enum EventImportanceextension EventImportance : Equatable, Hashable, Sendable -
Describes a field of a Trait, Command, Event, etc.
Declaration
Swift
protocol Field : Hashable, RawRepresentable, Sendable where Self.RawValue == UInt32 -
The possible value types for a field.
Declaration
Swift
enum FieldTypeextension FieldType : Equatable, Sendable -
Undocumented
Declaration
Swift
protocol ForceReadableTrait : Trait -
Top-level entry to the GoogleHomeSDK.
Declaration
Swift
final class Homeextension Home : Sendable -
A single smart home device.
Declaration
Swift
struct HomeDeviceextension HomeDevice : Equatable, Hashable, HomeObject, HomeObjectImpl, Identifiable, ObjectDataRepresentable, Sendable -
Base type for all errors thrown by the GoogleHomeSDK.
Declaration
Swift
struct HomeErrorextension HomeError : Copyable, CustomNSError, Equatable, Error, Error, Escapable, Hashable, Sendable, Sendable -
Undocumented
Declaration
Swift
struct MatterErrorextension MatterError : Equatable, Hashable, Sendable -
Decommission specific errors.
Declaration
Swift
enum DecommissionErrorextension DecommissionError : Equatable, Hashable, Sendable -
Discriminator for specific subclass of
HomeObject.Declaration
Swift
enum HomeObjectTypeextension HomeObjectType : Equatable, Hashable, Sendable -
Base protocol for all entity classes returned from the GoogleHomeSDK.
Declaration
Swift
protocol HomeObject : Hashable, Identifiable, Sendable where Self.ID == Stringextension HomeObject : Equatable -
Type-erased
HomeObjectwrapper.Declaration
Swift
struct AnyHomeObjectextension AnyHomeObject : Equatable, Hashable, HomeObject, Identifiable, Sendable -
Represents a hub discovered by mDNS service discovery.
Declaration
Swift
struct Hubextension Hub : Equatable, Hashable, Sendable -
Undocumented
Declaration
Swift
typealias ClusterID = String -
Undocumented
Declaration
Swift
protocol NamespaceProvider -
The GHP-specific trait id for a command within a cluster.
Example: home.matter.0000.clusters.0006.00000001
Declaration
-
The GHP-specific trait ID for an event within a cluster.
Matter Example: home.matter.0000.clusters.0045.00000000 –> The StateChange Event (ID 0x0000) of the Boolean State Cluster (ID 0x0045).
Non-Matter Example: home.platform.traits.TimeTrait.ScheduledEvent –> The ScheduledEvent Event (ID “ScheduledEvent”) of the TimeTrait (ID “TimeTrait”).
Declaration
-
A protocol for the request of a Matter command.
Declaration
Swift
protocol CommandRequest : Sendable -
A protocol for the response of a Matter command.
Declaration
Swift
protocol CommandResponse : Sendable -
Abstraction for the Interaction Client.
Declaration
Swift
protocol InteractionProxy : Sendable -
Network locality of request.
Declaration
Swift
enum LocalityTypeextension LocalityType : Equatable, Hashable, Sendable -
Represents a query against the User’s home graph.
Declaration
Swift
protocol Query<Element> : Sendable -
Represents individual object updates.
Declaration
Swift
enum HomeObjectUpdate<Element> where Element : Hashable, Element : Sendableextension HomeObjectUpdate : Equatable, Hashable, Sendable -
Represents a single room in the User’s home graph.
Declaration
Swift
struct Roomextension Room : Equatable, Hashable, HomeObject, HomeObjectImpl, Identifiable, ObjectDataRepresentable, Sendable -
Undocumented
Declaration
Swift
struct SemanticTagextension SemanticTag : Equatable, Hashable, Sendable -
Connectivity metadata for a trait.
Declaration
Swift
struct SourceConnectivityextension SourceConnectivity : Equatable, Hashable, Sendable -
Represents a structure in the User’s home graph.
Declaration
Swift
struct Structureextension Structure : AutomationManager, Copyable, Copyable, Equatable, Escapable, Escapable, Hashable, HomeObject, HomeObjectImpl, Identifiable, ObjectDataRepresentable, Sendable, Sendable, Updatable -
Undocumented
Declaration
Swift
protocol MutableStructureData : AnyObject -
Errors that cause a subscription to fail.
Declaration
Swift
enum SubscriptionErrorextension SubscriptionError : Error, Sendable -
Basic interface for object Traits.
Declaration
Swift
protocol Trait : TraitEncodable, CustomStringConvertible, Hashable, Sendableextension Trait : Equatable -
Tag identifies the field for a single attribute. Both JSON and Protobuf encoding use UInt32 to identify the encoding fields.
Declaration
Swift
typealias TagID = UInt32 -
Supported Scalar types.
Declaration
Swift
protocol Scalar : Hashable, Sendable -
Undocumented
Declaration
Swift
protocol DefaultConstructible -
Supported Bitmap types.
Declaration
Swift
protocol BitmapStorage : DefaultConstructible, Scalar, UnsignedInteger -
Undocumented
Declaration
Swift
protocol Bitmap : AutomationValue, OptionSet where Self.RawValue : BitmapStorageextension Bitmap : Equatable, ExpressibleByArrayLiteral, Hashable, RawRepresentable, Sendable, SetAlgebra -
Undocumented
Declaration
Swift
protocol Enum : AutomationValue, RawRepresentable where Self.RawValue == UInt64 -
Undocumented
Declaration
Swift
protocol Enum8 : Enum -
Undocumented
Declaration
Swift
protocol Enum16 : Enum -
Undocumented
Declaration
Swift
protocol Enum32 : Enum -
Interface for enumerations in Platform traits.
Declaration
Swift
protocol PlatformEnum : Enum32 -
Serializable abstraction for Structure data objects.
Declaration
Swift
protocol StructDataRepresentable : AutomationValueextension StructDataRepresentable : Equatable, Hashable, Sendable -
Property wrapper for trait attributes, which contains metadata about the attribute.
Declaration
Swift
@propertyWrapper struct TraitAttribute<Value> where Value : Sendableextension TraitAttribute : Sendable -
TraitCollectionis a collection of already-fetched trait data.Declaration
Swift
final class TraitCollectionextension TraitCollection : Equatable, Hashable, Sendable -
Controller for accessing traits on an object.
Declaration
Swift
protocol TraitController : Sendable -
Public interface for decoding Trait data.
Declaration
Swift
struct TraitDecoder -
Basic interface for entities that can be encoded as Traits.
Declaration
Swift
protocol TraitEncodable -
Public interface for encoding Trait data.
Declaration
Swift
final class TraitEncoder -
General metadata about a
Trait.Declaration
Swift
struct TraitMetadataextension TraitMetadata : Equatable, Hashable, Sendable -
Container representing an encoded trait payload.
Declaration
Swift
struct TraitPayloadextension TraitPayload : Equatable, Hashable, Sendable -
Model representing a Commissionable Matter device, corresponding to the proto used by the MatterCommissionerTrait.
Declaration
Swift
struct MatterCommissionableDeviceextension MatterCommissionableDevice : AutomationValue, Decodable, Encodable, Equatable, Hashable, Sendable, StructDataRepresentable -
An internal protocol to encapsulate logic shared across Matter cluster classes.
Declaration
Swift
protocol MatterTrait : Traitextension MatterTrait : CustomStringConvertible, Equatable, Hashable, Sendable, TraitEncodable -
Represents a postal address, such as for postal delivery or payments addresses.
Declaration
Swift
struct PostalAddressextension PostalAddress : AutomationValue, Decodable, Encodable, Equatable, Hashable, Sendable, StructDataRepresentable -
Represents an unknown bitmap.
Declaration
Swift
struct UnknownBitmapextension UnknownBitmap : AutomationValue, Bitmap, Equatable, ExpressibleByArrayLiteral, Hashable, OptionSet, RawRepresentable, Sendable, SetAlgebra -
A struct that represents an unknown device type.
Declaration
Swift
struct UnknownDeviceTypeextension UnknownDeviceType : CustomDebugStringConvertible, DeviceType, Equatable, Hashable, Sendable -
Represents an unknown enum.
Declaration
Swift
struct UnknownEnumextension UnknownEnum : AutomationValue, Enum, Equatable, Hashable, RawRepresentable, Sendable -
Represents an unknown field.
Declaration
Swift
struct UnknownFieldextension UnknownField : Equatable, Field, Hashable, RawRepresentable, Sendable -
Represents an unknown
HomeObjectDeclaration
Swift
struct UnknownHomeObjectextension UnknownHomeObject : Equatable, Hashable, HomeObject, Identifiable, Sendable -
Represents an unknown struct.
Declaration
Swift
struct UnknownStructextension UnknownStruct : AutomationValue, Equatable, Hashable, Sendable, StructDataRepresentable -
Represents an unknown
Trait.Declaration
Swift
struct UnknownTraitextension UnknownTrait : CustomStringConvertible, Equatable, Hashable, Sendable, Trait, TraitEncodable -
Declaration
Swift
extension Data : AutomationValue, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Scalar, Sendable, Sendable -
Declaration
Swift
extension Date : AutomationValue, Copyable, Equatable, Escapable, Hashable, Sendable, StructDataRepresentable -
-
Declaration
Swift
extension UserDefaults : Sendable -
Declaration
Swift
extension Array : AutomationValue, AutomationValueArray, Collection, Copyable, Copyable, Equatable, Escapable, Escapable, Hashable, Sendable, Sequence where Element : AutomationValue -
Declaration
Swift
extension Bool : AutomationValue, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Scalar, Sendable, Sendable -
Declaration
Swift
extension Double : AutomationValue, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Scalar, Sendable, Sendable -
Declaration
Swift
extension Duration : AutomationValue, AutomationValue, Copyable, Copyable, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Sendable, Sendable, StructDataRepresentable -
Declaration
Swift
extension Float : AutomationValue, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Scalar, Sendable, Sendable -
Declaration
Swift
extension Int : AutomationValue, Copyable, Equatable, Escapable, Hashable, Sendable -
Declaration
Swift
extension Int16 : AutomationValue, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Scalar, Sendable, Sendable -
Declaration
Swift
extension Int32 : AutomationValue, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Scalar, Sendable, Sendable -
Declaration
Swift
extension Int64 : AutomationValue, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Scalar, Sendable, Sendable -
Declaration
Swift
extension Int8 : AutomationValue, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Hashable, Hashable, Scalar, Sendable, Sendable -
Declaration
Swift
extension Optional : AutomationValue, Copyable, Copyable, Equatable, Escapable, Escapable, Hashable, OptionalAutomationValue, Sendable where Wrapped : AutomationValueextension Optional : Copyable, Escapable, OptionalAutomationValueArray where Wrapped : AutomationValueArrayextension Optional : Copyable, Escapable, OptionalComparable where Wrapped : Comparableextension Optional : Copyable, Escapable, OptionalNumeric where Wrapped : Numericextension Optional : Copyable, Escapable, OptionalSignedInteger where Wrapped : SignedIntegerextension Optional : Copyable, Escapable, OptionalUnsignedInteger where Wrapped : UnsignedInteger -
Declaration
Swift
extension String : AutomationValue, Copyable, Copyable, Copyable, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, Escapable, Hashable, Hashable, NamespaceProvider, Scalar, Sendable, Sendable -
Declaration
Swift
extension UInt : AutomationValue, Copyable, Equatable, Escapable, Hashable, Sendable -
Declaration
Swift
extension UInt16 : AdditiveArithmetic, AutomationValue, BinaryInteger, BitmapStorage, Comparable, Copyable, Copyable, CustomStringConvertible, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, ExpressibleByIntegerLiteral, Hashable, Hashable, Numeric, Scalar, Sendable, Sendable, Strideable, UnsignedInteger -
Declaration
Swift
extension UInt32 : AdditiveArithmetic, AutomationValue, BinaryInteger, BitmapStorage, Comparable, Copyable, Copyable, CustomStringConvertible, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, ExpressibleByIntegerLiteral, Hashable, Hashable, Numeric, Scalar, Sendable, Sendable, Strideable, UnsignedInteger -
Declaration
Swift
extension UInt64 : AdditiveArithmetic, AutomationValue, BinaryInteger, BitmapStorage, Comparable, Copyable, Copyable, CustomStringConvertible, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, ExpressibleByIntegerLiteral, Hashable, Hashable, Numeric, Scalar, Sendable, Sendable, Strideable, UnsignedInteger -
Declaration
Swift
extension UInt8 : AdditiveArithmetic, AutomationValue, BinaryInteger, BitmapStorage, Comparable, Copyable, Copyable, CustomStringConvertible, DefaultConstructible, Equatable, Equatable, Escapable, Escapable, ExpressibleByIntegerLiteral, Hashable, Hashable, Numeric, Scalar, Sendable, Sendable, Strideable, UnsignedInteger