Skip to main content

createSoundMessageFromFullPath

Feature Introduction

Note

Create an audio message. The SDK internally extracts audio information based on the full path and creates an audio message.

Function Prototype


+ (OIMMessageInfo *)createSoundMessageFromFullPath:(NSString *)soundPath
duration:(NSInteger)duration;

Input Parameters

Parameter NameParameter TypeMandatoryDescription
soundPathNSStringYesAbsolute path
durationNSIntegerYesDuration

Return Result

NameTypeDescription
messageOIMMessageInfoSuccess return

Code Example


OIMMessageInfo *message = [OIMMessageInfo createSoundMessageFromFullPath:@"" duration:1];