(
f: (queue: Queue.Queue<A, E | Cause.Done>) => Effect.Effect<unknown, E, R | Scope.Scope>,
options?: {
readonly bufferSize?: number | undefined
readonly strategy?: "sliding" | "dropping" | "suspend" | undefined
}
)
| 540 | * @since 4.0.0 |
| 541 | */ |
| 542 | export const callback = <A, E = never, R = never>( |
| 543 | f: (queue: Queue.Queue<A, E | Cause.Done>) => Effect.Effect<unknown, E, R | Scope.Scope>, |
| 544 | options?: { |
| 545 | readonly bufferSize?: number | undefined |
| 546 | readonly strategy?: "sliding" | "dropping" | "suspend" | undefined |
| 547 | } |
| 548 | ): Channel<A, E, void, unknown, unknown, unknown, Exclude<R, Scope.Scope>> => |
| 549 | fromTransform((_, scope) => Effect.map(asyncQueue(scope, f, options), Queue.take)) |
| 550 | |
| 551 | /** |
| 552 | * Creates a `Channel` that interacts with a callback function using a queue, emitting arrays. |
nothing calls this directly
no test coverage detected