Inherits from NSObject
Declared in Bit6AudioRecorderController.h

Overview

Bit6AudioRecorderController is used to record an audio file and attach it to a message.

Properties

duration

Gets the length of the current recording - only valid while recording

@property (nonatomic, readonly) double duration

Declared In

Bit6AudioRecorderController.h

isRecording

Used to know if there’s a recording in process.

@property (nonatomic, readonly) BOOL isRecording

Declared In

Bit6AudioRecorderController.h

Instance Methods

cancelRecording

Cancel a recording without saving the audio file.

- (void)cancelRecording

Declared In

Bit6AudioRecorderController.h

startRecordingAudioWithMaxDuration:delegate:defaultPrompt:errorHandler:

Tries to start to record an audio file. It can show an object as the UI control to cancel or finish the recording.

- (void)startRecordingAudioWithMaxDuration:(NSTimeInterval)maxDuration delegate:(nullable id<Bit6AudioRecorderControllerDelegate>)delegate defaultPrompt:(BOOL)defaultPrompt errorHandler:(nullable void ( ^ ) ( NSError *_Nullable error ))errorHandler

Parameters

maxDuration

maximum allowed duration (in seconds) of the audio file to be recorded.

delegate

the delegate to be notified when the recording has been completed or canceled. For details about the methods that can be implemented by the delegate, see Bit6AudioRecorderControllerDelegate Protocol Reference.

defaultPrompt

if YES then a default UIAlertView will be shown to handle the recording. If NO then you need to provide a custom UI to handle the recording.

errorHandler

used to determine if an error occurs

Declared In

Bit6AudioRecorderController.h

stopRecording

Finish the recording and saves the audio file to cache.

- (void)stopRecording

Declared In

Bit6AudioRecorderController.h