<!--
{
  "availability" : [
    "iOS: 26.0.0 -",
    "iPadOS: 26.0.0 -",
    "macCatalyst: 26.0.0 -",
    "macOS: 26.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: 26.0.0 -",
    "watchOS: 26.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "DataDetection",
  "identifier" : "/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "DataDetection"
    ],
    "preciseIdentifier" : "s:13DataDetection0A8DetectorO5MatchV15SemanticDetailsO13CalendarEventV"
  },
  "title" : "DataDetector.Match.SemanticDetails.CalendarEvent"
}
-->

# DataDetector.Match.SemanticDetails.CalendarEvent

The values the framework returns that represent date components of a calendar event.

```
struct CalendarEvent
```

## Discussion

You can use these properties to populate an Event. The event may contain just a single date, such as a start date, but can contain both a start and end date.

- [`allDay`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/allDay) is `true` if the date or date range doesn’t specify a time.
- [`startDate`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/startDate) may contain the start date of the event.
- [`endDate`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/endDate) may contain the end date of the event.
- [`endTimeZone`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/endTimeZone) may contain the time zone of the end date of the event.
- [`startTimeZone`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/startTimeZone) may contain the time zone of the start date of the event.

## Topics

### Calendar event properties

[`let allDay: Bool`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/allDay)

A Boolean value that indicates whether the event is an all-day event.

[`let startDate: Date?`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/startDate)

An optional date that may contain the start date of the event.

[`let endDate: Date?`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/endDate)

An optional date that may contain the end date of the event.

[`let startTimeZone: TimeZone?`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/startTimeZone)

An optional time zone object that may contain the time zone of the start date of the event.

[`let endTimeZone: TimeZone?`](/documentation/DataDetection/DataDetector/Match/SemanticDetails/CalendarEvent/endTimeZone)

An optional time zone object that may contain the time zone of the end date of the event.

## Relationships

### Conforms To

[`Escapable`](/documentation/Swift/Escapable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`Hashable`](/documentation/Swift/Hashable)

[`Encodable`](/documentation/Swift/Encodable)

[`Equatable`](/documentation/Swift/Equatable)

[`Sendable`](/documentation/Swift/Sendable)

[`Decodable`](/documentation/Swift/Decodable)

[`Copyable`](/documentation/Swift/Copyable)

---

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)