Package org.jcsp.net
Class NetChannelInputProcess
- java.lang.Object
-
- org.jcsp.net.NetChannelInputProcess
-
-
Field Summary
Fields Modifier and Type Field Description private ChannelMessage.AckackAprivate ChannelMessage.AckackBprivate Alternativealtprivate ChannelIDchannelIDOur channel ID.private longchannelIndexOur channel index.private AltingChannelInputfromNetInThe channel we use for recieving from the demuxes.private SharedChannelOutputfromNetOutprivate java.lang.StringnameThe name of this channel.private RejectableChanneloutThe channel used for output.private booleansendAckAprivate Any2OneChannelstopChannel
-
Constructor Summary
Constructors Constructor Description NetChannelInputProcess(java.lang.String label, RejectableChannel out)Constructor which takes a label to assign to the channel's VCN and aChannelOutputobject on which to output any data received from over the network.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) voidbreakChannel()(package private) longgetChannelIndex()private java.lang.ObjectreadFromNetChannel()Reads a message from the network communications channel.voidrun()Handle this link.
-
-
-
Field Detail
-
channelIndex
private long channelIndex
Our channel index.
-
channelID
private ChannelID channelID
Our channel ID.
-
name
private java.lang.String name
The name of this channel.
-
fromNetIn
private AltingChannelInput fromNetIn
The channel we use for recieving from the demuxes.
-
fromNetOut
private SharedChannelOutput fromNetOut
-
out
private RejectableChannel out
The channel used for output.
-
stopChannel
private Any2OneChannel stopChannel
-
alt
private Alternative alt
-
ackA
private transient ChannelMessage.Ack ackA
-
ackB
private transient ChannelMessage.Ack ackB
-
sendAckA
private transient boolean sendAckA
-
-
Constructor Detail
-
NetChannelInputProcess
NetChannelInputProcess(java.lang.String label, RejectableChannel out)Constructor which takes a label to assign to the channel's VCN and aChannelOutputobject on which to output any data received from over the network.- Parameters:
label- the label to assign to the VCN. If this isnullthen no label will be assigned.out- theChannelOutput object on which to forward any data received from over the network.
-
-
Method Detail
-
breakChannel
void breakChannel()
-
getChannelIndex
long getChannelIndex()
-
readFromNetChannel
private java.lang.Object readFromNetChannel()
Reads a message from the network communications channel. Acknowledges and ignores LinkLost messages.- Returns:
- The first Message read from the network.
-
-