1.0.3 • Published 2 years ago

@types/jrf-pip v1.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

Installation

npm install --save @types/jrf-pip

Summary

This package contains type definitions for jrf-pip (https://github.com/jirufik/jrf-pip#readme).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jrf-pip.

index.d.ts

// Type definitions for jrf-pip 1.0
// Project: https://github.com/jirufik/jrf-pip#readme
// Definitions by: rufus <https://github.com/jirufik>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped

interface ParallelProcessingParams<T> {
    arrayValues: T[];

    processingFn(params: ProcessingFnParams<T>): void | Promise<void>;

    nextValueFn?(params: NextValueFnParams<T>): boolean | Promise<boolean>;

    cycleTimeout?: number | undefined;
    parallel?: number | undefined;
    awaitRes?: boolean | undefined;

    cb?(stackError: StackError<T>): void | Promise<void>;
}

interface ProcessingFnParams<T> {
    value: T;
    index: number;
    arrayValues: T[];
    iteration: number;
}

interface NextValueFnParams<T> {
    value: T;
    index: number;
    arrayValues: T[];
    iteration: number;
}

interface StackError<T> {
    value: T;
    index: number;
    iteration: number;
    error: any;
}

declare function parallelProcessing<T>(params: ParallelProcessingParams<T>): Promise<Array<StackError<T>>> | undefined;

export = parallelProcessing;

Additional Details

  • Last updated: Thu, 08 Jul 2021 16:22:45 GMT
  • Dependencies: none
  • Global values: none

Credits

These definitions were written by rufus.

1.0.2

2 years ago

1.0.3

2 years ago

1.0.1

4 years ago

1.0.0

5 years ago