9#import <Foundation/Foundation.h>
11NS_ASSUME_NONNULL_BEGIN
61@property (nonatomic,copy) NSString *
url;
74@protocol NIMMediaManagerDelegate <NSObject>
84- (void)playAudio:(NSString *)filePath didBeganWithError:(nullable NSError *)error;
92- (void)playAudio:(NSString *)filePath didCompletedWithError:(nullable NSError *)error;
100- (void)playAudio:(NSString *)filePath progress:(
float)value;
108- (void)stopPlayAudio:(NSString *)filePath didCompletedWithError:(nullable NSError *)error;
113- (void)playAudioInterruptionBegin;
118- (void)playAudioInterruptionEnd;
127- (void)recordAudio:(nullable NSString *)filePath didBeganWithError:(nullable NSError *)error;
135- (void)recordAudio:(nullable NSString *)filePath didCompletedWithError:(nullable NSError *)error;
140- (void)recordAudioDidCancelled;
147- (void)recordAudioProgress:(NSTimeInterval)currentTime;
152- (void)recordAudioInterruptionBegin;
157- (void)recordAudioInterruptionEnd;
164@protocol NIMMediaManager <NSObject>
172@property (nonatomic, assign) NSTimeInterval recordProgressUpdateTimeInterval;
174#pragma mark - play audio
190- (void)setNeedProximityMonitor:(BOOL)needProximityMonitor;
205- (void)play:(NSString *)filepath;
220- (BOOL)seek:(NSTimeInterval)timestamp;
222#pragma mark - record audio
237- (void)recordForDuration:(NSTimeInterval)duration;
246 duration:(NSTimeInterval)duration;
266- (float)recordPeakPower;
272- (float)recordAveragePower;
285#pragma mark - common setting
291- (void)disableResetAudioSession:(BOOL)disabled;
298- (void)setDeactivateAudioSessionAfterComplete:(BOOL)deactivate;
300#pragma mark - delegates
306- (void)addDelegate:(
id<NIMMediaManagerDelegate>)delegate;
313- (void)removeDelegate:(
id<NIMMediaManagerDelegate>)delegate;
Definition: NIMMediaManagerProtocol.h:56
NSString * filepath
Definition: NIMMediaManagerProtocol.h:67
NSString * url
Definition: NIMMediaManagerProtocol.h:61