Multicast
structureMulticast channels provide a mechanism for broadcasting a stream of messages to a collection of threads. Threads receive multicast messages via an output port; each port receives its own copy of every message sent since the port was created. Multicast channels are particularly useful for communicating with a dynamically varying group of threads, since the sender does not need to know how many threads are listening.
signature MULTICAST
structure Multicast
: MULTICAST
type 'a event = 'a CML.event
type 'a mchan
type 'a port
val mChannel : unit -> 'a mchan
val port : 'a mchan -> 'a port
val copy : 'a port -> 'a port
val recv : 'a port -> 'a
val recvEvt : 'a port -> 'a event
val multicast : ('a mchan * 'a) -> unit
type 'a event
type 'a mchan
type 'a port
mChannel ()
port mc
copy p
recv p
recvEvt p
multicast (mc, v)
Last Modified January 29, 1997
Comments to John Reppy.
Copyright © 1997 Bell Labs, Lucent Technologies