public final class Demultiplex extends java.lang.Object implements CSProcess
Multiplex
process on the other
end of its in channel back into separate streams (its out
channels). It assumes that Multiplex
operates on the same
size array of channels as its out array.
The protocol on the incoming multiplexed stream consists of an Integer, that represents the channel identity of the multiplexed data, followed by the multiplexed data.
Input Channels | ||
---|---|---|
in | java.lang.Integer, java.lang.Object | A channel index followed by the multiplexed data. |
Output Channels | ||
out[] | java.lang.Object | All channels in this package carry integers. |
Multiplex
,
Paraplex
,
Deparaplex
Modifier and Type | Field and Description |
---|---|
private ChannelInput |
in
The input Channel
|
private ChannelOutput[] |
out
The output Channels
|
Constructor and Description |
---|
Demultiplex(ChannelInput in,
ChannelOutput[] out)
Construct a new Demultiplex process with the input Channel in and the output
Channels out.
|
Modifier and Type | Method and Description |
---|---|
void |
run()
The main body of this process.
|
private final ChannelInput in
private final ChannelOutput[] out
public Demultiplex(ChannelInput in, ChannelOutput[] out)
in
- the input channelout
- the output channels