# CapturedResultReceiver

The `CapturedResultReceiver` interface is designed as a standardized way for retrieving captured results in the Dynamsoft Capture Vision architecture. By implementing the `CapturedResultReceiver`, you will receive the callback of the various types of *captured results*, such a decoded barcode (Barcode Reader), a recognized text line (Label Recognizer), a detected quad (Document Normalizer), a normalized image (Document Normalizer), or parsed data (Code Parser). The `CapturedResultReceiver` can add a receiver for any type of captured result or for a specific type of captured result, based on the method that is implemented.

## Definition

*Assembly:* dynamsoft_capture_vision_flutter

```dart
class CapturedResultReceiver
```

## Methods

| Method | Description |
| ------ | ----------- |
| [`onCapturedResultReceived`](#oncapturedresultreceived) | The callback invoked when captured results become available. It is triggered once for each image after its processing is completed. |
| [`onDecodedBarcodesReceived`](#ondecodedbarcodesreceived) | The callback invoked when decoded barcodes become available. It is triggered once for each image after its processing is completed. |
| [`onParsedResultsReceived`](#onparsedreultsreceived) | The callback invoked when parsed results become available. It is triggered once for each image after its processing is completed.|
| [`onProcessedDocumentResultReceived`](#onparsedreultsreceived) | The callback invoked when processed document results become available. It is triggered once for each image after its processing is completed. |
| [`onRecognizedTextLinesReceived`](#onparsedreultsreceived) | The callback invoked when recognized text lines become available. It is triggered once for each image after its processing is completed. |

### onCapturedResultReceived

This callback method delivers a [`CapturedResult`](https://www.dynamsoft.com/capture-vision/docs/mobile/programming/flutter/api-reference/capture-vision-router/captured-result.md) - an object representing any kind of captured result item that is captured from an image or a video frame. The callback is triggered each time an image finishes processing, regardless of whether there is a valid result or not.

```dart
Future<void> Function(CapturedResult result)? onCapturedResultReceived;
```

**Parameters**

`result`: The captured result, an instance of [`CapturedResult`](https://www.dynamsoft.com/capture-vision/docs/mobile/programming/flutter/api-reference/capture-vision-router/captured-result.md).

### onDecodedBarcodesReceived

This callback method delivers a [`DecodedBarcodesResult`](https://www.dynamsoft.com/barcode-reader/docs/mobile/programming/flutter/api-reference/barcode-reader/decoded-barcodes-result.md), which is an object representing any captured result of type `barcode` that is taken from an image or a video frame. The callback is triggered each time an image finishes processing, regardless of whether there is a valid result or not.

```dart
Future<void> Function(DecodedBarcodesResult result)? onDecodedBarcodesReceived;
```

**Parameters**

`result`: The decoded barcode result, an instance of [`DecodedBarcodesResult`](https://www.dynamsoft.com/barcode-reader/docs/mobile/programming/flutter/api-reference/barcode-reader/decoded-barcodes-result.md).

### onParsedReultsReceived

This callback method delivers a [`ParsedResult`](https://www.dynamsoft.com/code-parser/docs/mobile/programming/flutter/api-reference/parsed-result.md), which is an object representing any captured result of type `parsedResult` that is taken from an image or a video frame. The callback is triggered each time an image finishes processing, regardless of whether there is a valid result or not.

```dart
Future<void> Function(ParsedResult result)? onParsedResultsReceived;
```

**Parameters**

`result`: The parsed result, an instance of [`ParsedResult`](https://www.dynamsoft.com/code-parser/docs/mobile/programming/flutter/api-reference/parsed-result.md).

### onProcessedDocumentResultReceived

This callback method delivers a [`ProcessedDocumentResult`](https://www.dynamsoft.com/document-normalizer/docs/mobile/programming/flutter/api-reference/processed-document-result.md), which is an object representing any captured result of type `detectedQuad`, `deskewedImage` and `enhancedImage` that is taken from an image or a video frame. The callback is triggered each time an image finishes processing, regardless of whether there is a valid result or not.

```dart
Future<void> Function(ProcessedDocumentResult result)? onProcessedDocumentResultReceived;
```

**Parameters**

`result`: The document processing results, an instance of [`ProcessedDocumentResult`](https://www.dynamsoft.com/document-normalizer/docs/mobile/programming/flutter/api-reference/processed-document-result.md).

### onRecognizedTextLinesReceived

This callback method delivers a [`RecognizedTextLinesResult`](https://www.dynamsoft.com/label-recognition/docs/mobile/programming/flutter/api-reference/recognized-text-lines-result.md), which is an object representing any captured result of type `recognizedTextLines` that is taken from an image or a video frame. The callback is triggered each time an image finishes processing, regardless of whether there is a valid result or not.

```dart
Future<void> Function(RecognizedTextLinesResult result)? onRecognizedTextLinesReceived;
```

**Parameters**

`result`: The text recognition result, an instance of [`RecognizedTextLinesResult`](https://www.dynamsoft.com/label-recognition/docs/mobile/programming/flutter/api-reference/recognized-text-lines-result.md).
