定义于:batcher.ts:6
用于配置 Batcher 实例的选项
• TValue
optional getShouldExecute: (items, batcher) => boolean;
optional getShouldExecute: (items, batcher) => boolean;
定义于:batcher.ts:11
用于确定是否应处理批处理的自定义函数 返回 true 以立即处理批处理
TValue[]
Batcher<TValue>
boolean
optional maxSize: number;
optional maxSize: number;
定义于:batcher.ts:16
批处理中的最大项目数
Infinity
Infinity
optional onExecute: (batcher) => void;
optional onExecute: (batcher) => void;
定义于:batcher.ts:20
处理批处理后触发的回调
Batcher<TValue>
void
optional onIsRunningChange: (batcher) => void;
optional onIsRunningChange: (batcher) => void;
定义于:batcher.ts:24
批处理器运行状态更改时触发的回调
Batcher<TValue>
void
optional onItemsChange: (batcher) => void;
optional onItemsChange: (batcher) => void;
定义于:batcher.ts:28
将项目添加到批处理器后触发的回调
Batcher<TValue>
void
optional started: boolean;
optional started: boolean;
定义于:batcher.ts:33
批处理器是否应立即开始处理
true
true
optional wait: number;
optional wait: number;
定义于:batcher.ts:40
处理批处理前等待的最长时间(���毫秒为单位)。 如果等待持续时间已过,则将处理该批处理。 如果未提供,则批处理不会因超时而触发。
Infinity
Infinity