<!--
{
  "availability" : [
    "iOS: 11.0.0 -",
    "iPadOS: 11.0.0 -",
    "macCatalyst: 11.0.0 -",
    "tvOS: 11.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 4.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "HomeKit",
  "identifier" : "/documentation/HomeKit/HMDurationEvent",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "HomeKit"
    ],
    "preciseIdentifier" : "c:objc(cs)HMDurationEvent"
  },
  "title" : "HMDurationEvent"
}
-->

# HMDurationEvent

An event that ends after the specified time duration.

```
class HMDurationEvent
```

## Overview

Use a duration event to specify that a different event should end after a period of time.

## Topics

### Creating a duration event

[`init(duration:)`](/documentation/HomeKit/HMDurationEvent/init(duration:))

Creates a duration event with the specified time duration.

### Inspecting a duration event

[`duration`](/documentation/HomeKit/HMDurationEvent/duration)

The event’s duration, in seconds.



---

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)