Showing the changes to libraries/networking/src/BaseAssetScriptingInterface.cpp (1 of 4 files). Show all
Unified · Split
| @@ -68,6 +68,17 @@ Promise BaseAssetScriptingInterface::queryCacheMeta(const QUrl& url) { · 67 unmodified lines | |||
| 68 | return assetClient()->queryCacheMetaAsync(url, makePromise(__FUNCTION__)); | 68 | return assetClient()->queryCacheMetaAsync(url, makePromise(__FUNCTION__)); |
| 69 | } | 69 | } |
| 70 | 70 | ||
| 71 | /**jsdoc | ||
| 72 | * Data and information returned by {@link Assets.loadFromCache}. | ||
| 73 | * @typedef {object} Assets.LoadFromCacheResult | ||
| 74 | * @property {number} [byteLength] - The number of bytes in the retrieved data. | ||
| 75 | * @property {string} [contentType] - The automatically detected MIME type of the content. | ||
| 76 | * @property {ArrayBuffer} data - The data bytes. | ||
| 77 | * @property {Assets.CacheItemMetaData} metadata - Information on the cache item. | ||
| 78 | * @property {string|object|ArrayBuffer} [response] - The content of the response. | ||
| 79 | * @property {Assets.ResponseType} responseType - The type of the content in <code>response</code>. | ||
| 80 | * @property {string} url - The URL of the cache item. | ||
| 81 | */ | ||
| 71 | Promise BaseAssetScriptingInterface::loadFromCache(const QUrl& url, bool decompress, const QString& responseType) { | 82 | Promise BaseAssetScriptingInterface::loadFromCache(const QUrl& url, bool decompress, const QString& responseType) { |
| 72 | QVariantMap metaData = { | 83 | QVariantMap metaData = { |
| 73 | { "_type", "cache" }, | 84 | { "_type", "cache" }, |