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

Function makeNetChannel

packages/platform/node-shared/src/NodeSocket.ts:246–257  ·  view source on GitHub ↗
(
  options: Net.NetConnectOpts
)

Source from the content-addressed store, hash-verified

244 * @since 4.0.0
245 */
246export const makeNetChannel = <IE = never>(
247 options: Net.NetConnectOpts
248): Channel.Channel<
249 Array.NonEmptyReadonlyArray<Uint8Array>,
250 Socket.SocketError | IE,
251 void,
252 Array.NonEmptyReadonlyArray<Uint8Array | string | Socket.CloseEvent>,
253 IE
254> =>
255 Channel.unwrap(
256 Effect.map(makeNet(options), Socket.toChannelWith<IE>())
257 )
258
259/**
260 * Provides a `Socket.Socket` by opening a TCP connection with the supplied

Callers

nothing calls this directly

Calls 2

makeNetFunction · 0.85
mapMethod · 0.45

Tested by

no test coverage detected