<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "VisionKit",
  "identifier" : "/documentation/VisionKit/DataScannerViewController/TextContentType",
  "metadataVersion" : "0.1.0",
  "role" : "Enumeration",
  "symbol" : {
    "kind" : "Enumeration",
    "modules" : [
      "VisionKit"
    ],
    "preciseIdentifier" : "s:9VisionKit25DataScannerViewControllerC15TextContentTypeO"
  },
  "title" : "DataScannerViewController.TextContentType"
}
-->

# DataScannerViewController.TextContentType

Types of text that a data scanner recognizes.

```
enum TextContentType
```

## Overview

To configure a [`DataScannerViewController`](/documentation/VisionKit/DataScannerViewController), pass one or more options into its initializer. For example, the following code creates a data scanner that detects textual references to money.

```swift
let recognizedDataTypes:Set<DataScannerViewController.RecognizedDataType> = [
    .text(textContentType: .currency)
]

// Create the data scanner.
let dataScanner = DataScannerViewController(recognizedDataTypes: recognizedDataTypes)
```

## Topics

### Identifying content types

[`case URL`](/documentation/VisionKit/DataScannerViewController/TextContentType/URL)

The content type for a URL that appears in text.

[`case dateTimeDuration`](/documentation/VisionKit/DataScannerViewController/TextContentType/dateTimeDuration)

The content type for dates, times, and durations that appear in
text.

[`case emailAddress`](/documentation/VisionKit/DataScannerViewController/TextContentType/emailAddress)

The content type for an email address that appears in text.

[`case flightNumber`](/documentation/VisionKit/DataScannerViewController/TextContentType/flightNumber)

The content type for a vendor-specific flight number that appears in
text.

[`case fullStreetAddress`](/documentation/VisionKit/DataScannerViewController/TextContentType/fullStreetAddress)

The content type for a mailing address that appears in text.

[`case shipmentTrackingNumber`](/documentation/VisionKit/DataScannerViewController/TextContentType/shipmentTrackingNumber)

The content type for a vendor-specific parcel tracking number that
appears in text.

[`case telephoneNumber`](/documentation/VisionKit/DataScannerViewController/TextContentType/telephoneNumber)

The content type for a phone number that appears in text.

[`case currency`](/documentation/VisionKit/DataScannerViewController/TextContentType/currency)

The content type for currency.

### Comparing content types

## Relationships

### Conforms To

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

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

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

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

---

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)