<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 14.0.0 -",
    "tvOS: 10.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "HomeKit",
  "identifier" : "/documentation/HomeKit/HMEventTrigger/predicateForEvaluatingTrigger(occurringOn:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "HomeKit"
    ],
    "preciseIdentifier" : "c:objc(cs)HMEventTrigger(cm)predicateForEvaluatingTriggerOccurringOnDateWithComponents:"
  },
  "title" : "predicateForEvaluatingTrigger(occurringOn:)"
}
-->

# predicateForEvaluatingTrigger(occurringOn:)

Creates a predicate that evaluates whether the event occurred at the specified time.

```
class func predicateForEvaluatingTrigger(occurringOn dateComponents: DateComponents) -> NSPredicate
```

## Parameters

`dateComponents`

Date components that represent the time to compare with the time that the event occurred.

## Return Value

A predicate object that represents a condition to evaluate before executing the scene.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)