sflow
Version:
sflow is a powerful and highly-extensible library designed for processing and manipulating streams of data effortlessly. Inspired by the functional programming paradigm, it provides a rich set of utilities for transforming streams, including chunking, fil
32 lines • 1.31 kB
TypeScript
import { type Ord } from "rambda";
import { type FlowSource, sflow } from "./index";
interface MergeBy {
<T>(ordFn: (input: T) => Ord, srcs: FlowSource<FlowSource<T>>): sflow<T>;
<T>(ordFn: (input: T) => Ord): (srcs: FlowSource<FlowSource<T>>) => sflow<T>;
}
/**
* merge multiple stream by ascend order, assume all input stream is sorted by ascend
* output stream will be sorted by ascend too.
*
* if one of input stream is not sorted by ascend, it will throw an error.
*
* @param ordFn a function to get the order of input
* @param srcs a list of input stream
* @returns a new stream that merge all input stream by ascend order
* @deprecated use {@link mergeStreamsByAscend}, this will be removed in next major version
*/
export declare const mergeAscends: MergeBy;
/**
* merge multiple stream by ascend order, assume all input stream is sorted by ascend
* output stream will be sorted by ascend too.
*
* if one of input stream is not sorted by ascend, it will throw an error.
*
* @param ordFn a function to get the order of input
* @param srcs a list of input stream
* @returns a new stream that merge all input stream by ascend order
* @deprecated use {@link mergeStreamsByAscend}
*/
export declare const mergeDescends: MergeBy;
export {};
//# sourceMappingURL=mergeAscends.d.ts.map