// ets_tracing: off import * as CK from "../../../../Collections/Immutable/Chunk/index.js" import type * as O from "../../../../Option/index.js" import type * as C from "../core.js" import * as MapChunks from "./mapChunks.js" /** * Performs a filter and map in a single step. */ export function collect_( self: C.Stream, f: (a: A) => O.Option ): C.Stream { return MapChunks.mapChunks_(self, CK.collect(f)) } /** * Performs a filter and map in a single step. * * @ets_data_first collect_ */ export function collect(f: (a: A) => O.Option) { return (self: C.Stream) => collect_(self, f) }