---
title: DataDetector.Options
framework: datadetection
role: symbol
role_heading: Structure
path: datadetection/datadetector/options
---

# DataDetector.Options

A set of options you can use to refine the behavior of text scanning, and better interpret the semantic domain of the matches.

## Declaration

```swift
struct Options
```

## Overview

Overview These properties are only hints, so it’s best to not make assumptions about how the framework uses them: Set documentDate to the creation date of the scanned string, such as a text message reception date. The default is now. Set documentTimeZone to the time zone matching the documentDate. The default is a person’s current time zone. Set documentLanguageCode to the language code of the scanned string, for example, “en” for English. Only set this property if you know the target language with a high degree of confidence; otherwise, set to nil. Set documentRegion to the region relevant to the scanned string, if any. Only set this property if you know the region with a high degree of confidence; otherwise, set to nil.

## Topics

### Hints you can provide to add more context for the matching process

- [documentDate](datadetection/datadetector/options/documentdate.md)
- [documentLanguageCode](datadetection/datadetector/options/documentlanguagecode.md)
- [documentRegion](datadetection/datadetector/options/documentregion.md)
- [documentTimeZone](datadetection/datadetector/options/documenttimezone.md)

### Initializers

- [init()](datadetection/datadetector/options/init().md)

## Relationships

### Conforms To

- [Copyable](swift/copyable.md)
- [Decodable](swift/decodable.md)
- [Encodable](swift/encodable.md)
- [Equatable](swift/equatable.md)
- [Escapable](swift/escapable.md)
- [Hashable](swift/hashable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Structures

- [DataDetector.Match](datadetection/datadetector/match.md)
- [DataDetector.MatchType](datadetection/datadetector/matchtype.md)
