Agora RTC Objective-C API Reference Refactor

Instance Methods
<AgoraMusicPlayerProtocol> Protocol Reference

Inherits <NSObjectAgoraRtcMediaPlayerProtocol>.

## Instance Methods
(NSInteger) | - openMediaWithSongCode:startPos:
(NSInteger) | - setPlayMode:

## Method Documentation

## ◆ openMediaWithSongCode:startPos:

- (NSInteger) openMediaWithSongCode: |  | (NSInteger) | songCode
startPos: |  | (NSInteger) | startPos

Open a media file with specified parameters.

Parameters

  songCode | The identifier of the media file that you want to play.
  startPos | The playback position (ms) of the music file.

Returns
  - 0: Success.
  - < 0: Failure.

## ◆ setPlayMode:

- (NSInteger) setPlayMode: |  | (AgoraMusicPlayMode) | mode |

Set play mode.

Parameters

  model | play mode.

Returns
  - 0: Success.
  - < 0: Failure.