Contents

DataScannerViewController.TextContentType

Types of text that a data scanner recognizes.

Declaration

enum TextContentType

Mentioned in

Overview

To configure a DataScannerViewController, pass one or more options into its initializer. For example, the following code creates a data scanner that detects textual references to money.

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

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

Topics

Identifying content types

See Also

Recognizing text