This defines an interface for an any-to-any integer channel, safe for use by many writers and many readers.
Please note that this is a safely shared channel and not a multicaster. Currently, multicasting has to be managed by writing active processes (see DynamicDelta for an example of broadcasting).
All reading processes and writing processes commit to the channel (i.e. may not back off). This means that the reading processes may not Alternative<TT>ALT</TT> on this channel.
The default semantics of the channel is that of CSP -- i.e. it is zero-buffered and fully synchronised. A reading process must wait for a matching writer and vice-versa.
A factory pattern is used to create channel instances. The create methods of Channel allow creation of channels, arrays of channels and channels with varying semantics such as buffering with a user-defined capacity or overwriting with various policies. Standard examples are given in the org.jcsp.util package, but careful users may write their own.
Type | Name and description |
---|---|
SharedChannelInputInt |
in() |
SharedChannelOutputInt |
out() |