Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/rimbu/channel/custom/index.ts>RemoteChannel.Constructors

Rimbu is a TypeScript library focused on immutable, performant, and type-safe collections and other tools.
Go to Latest
interface RemoteChannel.Constructors
import { type RemoteChannel } from "https://deno.land/x/rimbu@1.1.0/channel/custom/index.ts";
const { Constructors } = RemoteChannel;

Defines the static RemoteChannel API.

Methods

createRead<T = void>(port: RemoteChannel.SimpleMessagePort, config: RemoteChannel.ReadConfig): Promise<Channel.Read<T>>

Resolves to a new read-only RemoteChannel using the given configuration.

createWrite<T = void>(port: RemoteChannel.SimpleMessagePort, config: RemoteChannel.WriteConfig): Promise<Channel.Write<T>>

Resolves to a new write-only RemoteChannel using the given configuration.

createCross<TSend = void, TReceive = TSend>(port: RemoteChannel.SimpleMessagePort, config: RemoteChannel.CrossConfig): Promise<CrossChannel<TSend, TReceive>>

Resolves to a new cross-channel RemoteChannel using the given configuration.