AliyunPlayer v6.21.0
Aliyun Player API Reference Manual for iOS Platforms
Loading...
Searching...
No Matches
AliMediaDownloader Class Reference

#include "AliMediaDownloader.h"

Inheritance diagram for AliMediaDownloader:

Instance Methods

(void) - deleteFile
 Delete the downloaded file.
 
(void) - destroy
 Delete the download object.
 
(AVDConfig *) - getConfig
 Query download config.
 
(instancetype) - init
 Intialize the download object.
 
(void) - prepareWithPlayAuth:
 Use AVPVidAuthSource to prepare for playback.
 
(void) - prepareWithVid:
 Use AVPVidStsSource to prepare for playback.
 
(void) - selectTrack:
 Specify the indexes of the tracks to be downloaded.
 
(void) - setConfig:
 Modify download config.
 
(void) - setPlayUrlConvertCallback:
 Set a URL conversion callback.
 
(void) - setSaveDirectory:
 Set a path to save the downloaded file.
 
(void) - start
 Start downloading.
 
(void) - stop
 Pause downloading.
 
(void) - updateWithPlayAuth:
 Update the AVPVidAuthSource information when the authentication expires.
 
(void) - updateWithVid:
 Update the AVPVidStsSource information when the authentication expires.
 

Class Methods

(int) + deleteFile:vid:format:index:
 Delete a downloaded file.
 
(NSString *) + getSDKVersion
 Query the SDK version.
 

Properties

id< AMDDelegatedelegate
 Set a proxy.
 
NSString * downloadedFilePath
 Query the path of the downloaded file.
 

Method Documentation

◆ deleteFile

- (void) deleteFile

Delete the downloaded file.

◆ deleteFile:vid:format:index:

+ (int) deleteFile: (NSString *) saveDir
vid: (NSString *) vid
format: (NSString *) format
index: (int) index 

Delete a downloaded file.

Parameters
saveDirThe path where the file is saved.
vidVID.
formatFormat.
indexThe download index corresponds to the VID.

◆ destroy

- (void) destroy

Delete the download object.

◆ getConfig

- (AVDConfig *) getConfig

Query download config.

◆ getSDKVersion

+ (NSString *) getSDKVersion

Query the SDK version.

◆ init

- (instancetype) init

Intialize the download object.

◆ prepareWithPlayAuth:

- (void) prepareWithPlayAuth: (AVPVidAuthSource *) source

Use AVPVidAuthSource to prepare for playback.

Parameters
sourcevid Play the media through playAuth.

◆ prepareWithVid:

- (void) prepareWithVid: (AVPVidStsSource *) source

Use AVPVidStsSource to prepare for playback.

Parameters
sourcevid Play the media through VidSts.

◆ selectTrack:

- (void) selectTrack: (int) trackIndex

Specify the indexes of the tracks to be downloaded.

Parameters
trackIndexUse the prepare callback to retrieve all track indexes.

◆ setConfig:

- (void) setConfig: (AVDConfig *) config

Modify download config.

◆ setPlayUrlConvertCallback:

- (void) setPlayUrlConvertCallback: (PlayURLConverCallback) callback

Set a URL conversion callback.

URL conversion is typically used in P2P broadcasting.

Parameters
callbackThe function pointer of the callback.

◆ setSaveDirectory:

- (void) setSaveDirectory: (NSString *) dir

Set a path to save the downloaded file.

Parameters
dirThe specified path.

◆ start

- (void) start

Start downloading.

◆ stop

- (void) stop

Pause downloading.

◆ updateWithPlayAuth:

- (void) updateWithPlayAuth: (AVPVidAuthSource *) source

Update the AVPVidAuthSource information when the authentication expires.

Parameters
sourcevid Authentication information.

◆ updateWithVid:

- (void) updateWithVid: (AVPVidStsSource *) source

Update the AVPVidStsSource information when the authentication expires.

Parameters
sourcevid STS information.

Property Documentation

◆ delegate

- (id<AMDDelegate>) delegate
readwritenonatomicweak

Set a proxy.

See AMDDelegate.

◆ downloadedFilePath

- (NSString*) downloadedFilePath
readnonatomicassign

Query the path of the downloaded file.


The documentation for this class was generated from the following file: