Skip to main content
Version: 1.5.x

Class PreDownloadContentOperation

Assembly: YooAsset.dll
View Source
Declaration
public abstract class PreDownloadContentOperation : AsyncOperationBase, IEnumerator

Methods

CreateResourceDownloader(int, int, int)

创建资源下载器,用于下载当前资源版本所有的资源包文件

View Source
Declaration
public virtual ResourceDownloaderOperation CreateResourceDownloader(int downloadingMaxNumber, int failedTryAgain, int timeout = 60)
Returns

YooAsset.ResourceDownloaderOperation

Parameters
TypeNameDescription
System.Int32downloadingMaxNumber同时下载的最大文件数
System.Int32failedTryAgain下载失败的重试次数
System.Int32timeout超时时间

CreateResourceDownloader(string, int, int, int)

创建资源下载器,用于下载指定的资源标签关联的资源包文件

View Source
Declaration
public virtual ResourceDownloaderOperation CreateResourceDownloader(string tag, int downloadingMaxNumber, int failedTryAgain, int timeout = 60)
Returns

YooAsset.ResourceDownloaderOperation

Parameters
TypeNameDescription
System.Stringtag资源标签
System.Int32downloadingMaxNumber同时下载的最大文件数
System.Int32failedTryAgain下载失败的重试次数
System.Int32timeout超时时间

CreateResourceDownloader(string[], int, int, int)

创建资源下载器,用于下载指定的资源标签列表关联的资源包文件

View Source
Declaration
public virtual ResourceDownloaderOperation CreateResourceDownloader(string[] tags, int downloadingMaxNumber, int failedTryAgain, int timeout = 60)
Returns

YooAsset.ResourceDownloaderOperation

Parameters
TypeNameDescription
System.String[]tags资源标签列表
System.Int32downloadingMaxNumber同时下载的最大文件数
System.Int32failedTryAgain下载失败的重试次数
System.Int32timeout超时时间

CreateBundleDownloader(string, int, int, int)

创建资源下载器,用于下载指定的资源依赖的资源包文件

View Source
Declaration
public virtual ResourceDownloaderOperation CreateBundleDownloader(string location, int downloadingMaxNumber, int failedTryAgain, int timeout = 60)
Returns

YooAsset.ResourceDownloaderOperation

Parameters
TypeNameDescription
System.Stringlocation资源定位地址
System.Int32downloadingMaxNumber同时下载的最大文件数
System.Int32failedTryAgain下载失败的重试次数
System.Int32timeout超时时间

CreateBundleDownloader(string[], int, int, int)

创建资源下载器,用于下载指定的资源列表依赖的资源包文件

View Source
Declaration
public virtual ResourceDownloaderOperation CreateBundleDownloader(string[] locations, int downloadingMaxNumber, int failedTryAgain, int timeout = 60)
Returns

YooAsset.ResourceDownloaderOperation

Parameters
TypeNameDescription
System.String[]locations资源定位地址列表
System.Int32downloadingMaxNumber同时下载的最大文件数
System.Int32failedTryAgain下载失败的重试次数
System.Int32timeout超时时间

Implements

  • System.Collections.IEnumerator