MCPcopy Create free account
hub / github.com/Effect-TS/effect / drain

Function drain

packages/effect/src/Channel.ts:3153–3172  ·  view source on GitHub ↗
(
  self: Channel<
    OutElem,
    OutErr,
    OutDone,
    InElem,
    InErr,
    InDone,
    Env
  >
)

Source from the content-addressed store, hash-verified

3151 * @since 2.0.0
3152 */
3153export const drain = <
3154 OutElem,
3155 OutErr,
3156 OutDone,
3157 InElem,
3158 InErr,
3159 InDone,
3160 Env
3161>(
3162 self: Channel<
3163 OutElem,
3164 OutErr,
3165 OutDone,
3166 InElem,
3167 InErr,
3168 InDone,
3169 Env
3170 >
3171): Channel<never, OutErr, OutDone, InElem, InErr, InDone, Env> =>
3172 transformPull(self, (pull) => Effect.succeed(Effect.forever(pull, { disableYield: true })))
3173
3174/**
3175 * Repeats this channel according to the provided schedule.

Callers

nothing calls this directly

Calls 2

transformPullFunction · 0.70
succeedMethod · 0.45

Tested by

no test coverage detected