record(forDuration:)
Records audio for the indicated duration of time.
Declaration
func record(forDuration duration: TimeInterval) -> BoolParameters
- duration:
The duration of time to record, in seconds.
Return Value
Discussion
The recorder stops recording when it reaches the indicated duration.
Calling this method implicitly calls prepareToRecord(), which creates an audio file and prepares the system for recording.