---
title: finalizeAndFinishThroughEndOfInput()
framework: speech
role: symbol
role_heading: Instance Method
path: speech/speechanalyzer/finalizeandfinishthroughendofinput()
---

# finalizeAndFinishThroughEndOfInput()

Finishes analysis after an audio input sequence has been terminated and fully consumed and the modules’ results are finalized.

## Declaration

```swift
final func finalizeAndFinishThroughEndOfInput() async throws
```

## Discussion

Discussion This method waits until the input sequence has been terminated and fully consumed, then finalizes like finalize(through:) and finishes analysis like finish(after:). If there is no input sequence, this method waits until there is an input sequence and the sequence terminates. If the input sequence is replaced using one of the start methods, this method continues waiting for the replacement input sequence to terminate. This method is primarily useful for autonomous analysis started via one of the start methods or a similar initializer. note: CancellationError if analysis is finished early before the end of input

## See Also

### Finishing analysis

- [cancelAndFinishNow()](speech/speechanalyzer/cancelandfinishnow().md)
- [finalizeAndFinish(through:)](speech/speechanalyzer/finalizeandfinish(through:).md)
- [finish(after:)](speech/speechanalyzer/finish(after:).md)
