Properties
Private parsing
parsing
: Cache<((err
: Error | null, data
?: T | null) => void)[]> = new Cache<CompleteCallback[]>()
Methods
parse
- parse(id: string, file: any, type: string, options: IDownloadParseOptions, onComplete: CompleteCallback): void
-
Parameters
-
id: string
-
file: any
-
type: string
-
options: IDownloadParseOptions
-
onComplete: CompleteCallback
Returns void
parseASTCTex
- parseASTCTex(file: ArrayBuffer | ArrayBufferView, options: IDownloadParseOptions, onComplete: CompleteCallback<IMemoryImageSource>): void
-
Parameters
-
file: ArrayBuffer | ArrayBufferView
-
options: IDownloadParseOptions
-
Returns void
parseAudio
- parseAudio(file: ArrayBuffer | HTMLAudioElement, options: IDownloadParseOptions, onComplete: CompleteCallback<AudioBuffer | HTMLAudioElement>): void
-
Parameters
-
file: ArrayBuffer | HTMLAudioElement
-
options: IDownloadParseOptions
-
onComplete: CompleteCallback<AudioBuffer | HTMLAudioElement>
Returns void
parseImage
- parseImage(file: HTMLImageElement | Blob, options: IDownloadParseOptions, onComplete: CompleteCallback<HTMLImageElement | ImageBitmap>): void
-
Parameters
-
file: HTMLImageElement | Blob
-
options: IDownloadParseOptions
-
onComplete: CompleteCallback<HTMLImageElement | ImageBitmap>
Returns void
parseImport
- parseImport(file: Record<string, any>, options: IDownloadParseOptions, onComplete: CompleteCallback<Asset>): void
-
Parameters
-
file: Record<string, any>
-
options: IDownloadParseOptions
-
onComplete: CompleteCallback<Asset>
Returns void
parsePKMTex
- parsePKMTex(file: ArrayBuffer | ArrayBufferView, options: IDownloadParseOptions, onComplete: CompleteCallback<IMemoryImageSource>): void
-
Parameters
-
file: ArrayBuffer | ArrayBufferView
-
options: IDownloadParseOptions
-
Returns void
parsePVRTex
- parsePVRTex(file: ArrayBuffer | ArrayBufferView, options: IDownloadParseOptions, onComplete: CompleteCallback<IMemoryImageSource>): void
-
Parameters
-
file: ArrayBuffer | ArrayBufferView
-
options: IDownloadParseOptions
-
Returns void
parsePlist
- parsePlist(file: string, options: IDownloadParseOptions, onComplete: CompleteCallback): void
-
Parameters
-
file: string
-
options: IDownloadParseOptions
-
onComplete: CompleteCallback
Returns void
register
-
Parameters
Returns void
-
Parameters
Returns void
Object literals
Private parsers
parsers: object
解析已下载的文件,parser 是一个单例, 所有成员能通过
cc.assetManaager.parser
访问