import { IBundleLoader } from "./IBundleLoader"; export interface OnlineBundleLoaderOptions { /** * The duration in ms determining how long an item * will stay in in-memory cache */ cacheDuration?: number; /** * The patch version. If not specified, the latest * will be used. */ patchVersion?: string; /** * The endpoint to use for fetching the files. */ endpoint?: URL; /** * Whether once downloaded bundles will be cached as files. * Default: true. */ cacheFile?: boolean; /** * The absolute path to a cache folder where files will be cached. * * @remarks The folder will be created if it not exists * @remarks Only used when `cacheFile` is true */ cacheDir?: string; } /** * Loads bundles from the content.ggpk from the web */ export declare class OnlineBundleLoader implements IBundleLoader { private readonly _weakCache; /** * To turn on debug information for this entity, add `Loader:*` * to the `DEBUG` environment variable */ private readonly _debug; private _options; private _state; constructor(options: OnlineBundleLoaderOptions); get Options(): Readonly>; updateOptions(options: Partial): void; fetchFile(filePath: string): Promise; private _optionsWithDefaults; private buildUrl; private _fetchFile; private _cache; private _fetchFromCache; private _tryLoadFromFile; }