| | |
| | | /** @typedef {import("../util/comparators").Comparator<EXPECTED_ANY>} Comparator */ |
| | | /** @typedef {import("../util/runtime").RuntimeSpec} RuntimeSpec */ |
| | | /** |
| | | * Defines the group config type used by this module. |
| | | * @template T, R |
| | | * @typedef {import("../util/smartGrouping").GroupConfig<T, R>} GroupConfig |
| | | */ |
| | |
| | | /** @typedef {import("./DefaultStatsFactoryPlugin").StatsProfile} StatsProfile */ |
| | | |
| | | /** |
| | | * Defines the known stats factory context type used by this module. |
| | | * @typedef {object} KnownStatsFactoryContext |
| | | * @property {string} type |
| | | * @property {Compilation} compilation |
| | |
| | | // StatsLogging StatsLoggingEntry |
| | | |
| | | /** |
| | | * Defines the stats object type used by this module. |
| | | * @template T |
| | | * @template F |
| | | * @typedef {T extends Compilation ? StatsCompilation : T extends ChunkGroupInfoWithName ? StatsChunkGroup : T extends Chunk ? StatsChunk : T extends OriginRecord ? StatsChunkOrigin : T extends Module ? StatsModule : T extends ModuleGraphConnection ? StatsModuleReason : T extends Asset ? StatsAsset : T extends ModuleTrace ? StatsModuleTraceItem : T extends Dependency ? StatsModuleTraceDependency : T extends Error ? StatsError : T extends ModuleProfile ? StatsProfile : F} StatsObject |
| | | */ |
| | | |
| | | /** |
| | | * Defines the created object type used by this module. |
| | | * @template T |
| | | * @template F |
| | | * @typedef {T extends ChunkGroupInfoWithName[] ? Record<string, StatsObject<ChunkGroupInfoWithName, F>> : T extends (infer V)[] ? StatsObject<V, F>[] : StatsObject<T, F>} CreatedObject |
| | |
| | | /** @typedef {EXPECTED_ANY} Result */ |
| | | |
| | | /** |
| | | * Defines the stats factory hooks type used by this module. |
| | | * @typedef {object} StatsFactoryHooks |
| | | * @property {HookMap<SyncBailHook<[ObjectForExtract, FactoryData, StatsFactoryContext], void>>} extract |
| | | * @property {HookMap<SyncBailHook<[FactoryDataItem, StatsFactoryContext, number, number], boolean | void>>} filter |
| | |
| | | */ |
| | | |
| | | /** |
| | | * Represents the stats factory runtime component. |
| | | * @template T |
| | | * @typedef {Map<string, T[]>} Caches |
| | | */ |
| | |
| | | } |
| | | |
| | | /** |
| | | * Get all level hooks. |
| | | * @template {StatsFactoryHooks[keyof StatsFactoryHooks]} HM |
| | | * @template {HM extends HookMap<infer H> ? H : never} H |
| | | * @param {HM} hookMap hook map |
| | |
| | | } |
| | | |
| | | /** |
| | | * Returns hook. |
| | | * @template {StatsFactoryHooks[keyof StatsFactoryHooks]} HM |
| | | * @template {HM extends HookMap<infer H> ? H : never} H |
| | | * @template {H extends import("tapable").Hook<any, infer R> ? R : never} R |
| | | * @template {H extends import("tapable").Hook<EXPECTED_ANY, infer R> ? R : never} R |
| | | * @param {HM} hookMap hook map |
| | | * @param {Caches<H>} cache cache |
| | | * @param {string} type type |
| | |
| | | } |
| | | |
| | | /** |
| | | * For each level waterfall. |
| | | * @template {StatsFactoryHooks[keyof StatsFactoryHooks]} HM |
| | | * @template {HM extends HookMap<infer H> ? H : never} H |
| | | * @param {HM} hookMap hook map |
| | |
| | | } |
| | | |
| | | /** |
| | | * For each level filter. |
| | | * @template {StatsFactoryHooks[keyof StatsFactoryHooks]} T |
| | | * @template {T extends HookMap<infer H> ? H : never} H |
| | | * @template {H extends import("tapable").Hook<any, infer R> ? R : never} R |
| | | * @template {H extends import("tapable").Hook<EXPECTED_ANY, infer R> ? R : never} R |
| | | * @param {T} hookMap hook map |
| | | * @param {Caches<H>} cache cache |
| | | * @param {string} type type |
| | |
| | | } |
| | | |
| | | /** |
| | | * Returns created object. |
| | | * @template FactoryData |
| | | * @template FallbackCreatedObject |
| | | * @param {string} type type |
| | |
| | | } |
| | | |
| | | /** |
| | | * Returns created object. |
| | | * @private |
| | | * @template FactoryData |
| | | * @template FallbackCreatedObject |