본문으로 건너뛰기

인터페이스: AsyncThrottlerState<TFn>

정의 위치: async-throttler.ts:8

타입 매개변수

TFn

TFnAnyAsyncFunction확장합니다.

속성

errorCount

errorCount: number;

정의 위치: async-throttler.ts:12

오류가 발생한 함수 실행 횟수입니다.


isExecuting

isExecuting: boolean;

정의 위치: async-throttler.ts:16

스로틀 함수가 현재 비동기로 실행 중인지 여부입니다.


isPending

isPending: boolean;

정의 위치: async-throttler.ts:20

스로틀러가 타임아웃에 의해 실행이 트리거되기를 기다리는 중인지 여부입니다.


lastArgs

lastArgs: Parameters<TFn> | undefined;

정의 위치: async-throttler.ts:24

가장 최근의 maybeExecute 호출에 전달된 인수입니다.


lastExecutionTime

lastExecutionTime: number;

정의 위치: async-throttler.ts:28

마지막 함수 실행 시점의 타임스탬프이며, 단위는 밀리초입니다.


lastResult

lastResult: Awaited<ReturnType<TFn>> | undefined;

정의 위치: async-throttler.ts:32

가장 최근에 성공한 함수 실행의 결과입니다.


maybeExecuteCount

maybeExecuteCount: number;

정의 위치: async-throttler.ts:36

maybeExecute가 호출된 횟수입니다(감소율 계산에 사용).


nextExecutionTime

nextExecutionTime: number | undefined;

정의 위치: async-throttler.ts:40

다음 실행이 가능한 시점의 타임스탬프이며, 단위는 밀리초입니다.


settleCount

settleCount: number;

정의 위치: async-throttler.ts:44

성공하거나 오류가 발생하여 완료된 함수 실행 횟수입니다.


status

status: "disabled" | "idle" | "executing" | "pending" | "settled";

정의 위치: async-throttler.ts:48

현재 실행 상태입니다. 활성 상태가 아니면 'idle', 대기 중이면 'pending', 실행 중이면 'executing', 완료되면 'settled'입니다.


successCount

successCount: number;

정의 위치: async-throttler.ts:52

성공적으로 완료된 함수 실행 횟수입니다.