- org.jcsp.lang.BlackHoleChannel
-
- All Implemented Interfaces and Traits:
- ChannelOutput
public class BlackHoleChannel
This implements ChannelOutput with black hole semantics.
Description
BlackHoleChannel is an implementation of ChannelOutput that yields
black hole semantics for the channel. Writers may always write but there can be
no readers. Any number of writers may share the same black hole.
Note: BlackHoleChannels are used for masking off unwanted outputs
from processes. They are useful when we want to reuse an existing process component
intact, but don't need some of its output channels (i.e. we don't want to redesign
and reimplement the component to remove the redundant channels). Normal channels cannot
be plugged in and left dangling as this may deadlock (parts of) the component being
reused.
- See Also:
- ChannelOutput
- One2OneChannel
- Any2OneChannel
- One2AnyChannel
- Any2AnyChannel
- Authors:
- P.H.Welch
-
-
Methods Summary
Methods
Type |
Name and description |
void |
poison(int strength)
|
void |
write(Object object) Write an Object to the channel and lose it. |
-
Inherited Methods Summary
-
-
Method Detail
-
public void poison(int strength)
- Summary:
Nested Field Constructor - Method
- | Detail:
Field Constructor - Method
JCSP for Java 1.8 generated 14-10-2016 by Jon Kerridge, Edinburgh Napier University - j dot kerridge at napier dot ac dot uk