A C D G H I L M N P R S T W

A

ACK_TYPE - Static variable in class Packet
Packet.ACK_TYPE is the type for acknowledgement packets.
add(int) - Method in class IntQueue
q.add(i) adds i to q.
add(Packet) - Method in class PacketQueue
q.add(i) adds i to q.
AlternatingBitProtocol - Class in <Unnamed>
An AlternatingBitProtocol implements the RDTProtocol interface using an alternating bit algorithm.
AlternatingBitProtocol() - Constructor for class AlternatingBitProtocol
 

C

CLOSE_TYPE - Static variable in class Packet
Packet.CLOSE_TYPE is the type for packets that close a connection.
createPacket() - Method in class RDTProtocol
createPacket() returns a new Packet that only requires setting its type, its identification number, and its sequence number before use.
createPacket() - Method in class TCPEntity.Context
cntxt.createPacket() returns a new packet that only requires setting its identification number an sequence number befor use.
createTimer() - Method in class RDTProtocol
createTimer() returns a new Timer that only requires setting its packet before use.
createTimer() - Method in class TCPEntity.Context
cntxt.createTimer() returns a new timer that only requires setting its packet before use.
createTimer(int, TimingTask) - Method in class TimerFactory
tq.createTimer(del, tsk) returns a Timer for use in tq that performs tsk with delay del after invoking start().

D

DATA_TYPE - Static variable in class Packet
Packet.DATA_TYPE is the type for data packets.
disconnect() - Method in class TCPEntity
tcpe.disconnect() is invoked to get tcpe to disconnect from its communication partner.
doInit() - Method in class AlternatingBitProtocol
rdtp.doInit() is invoked to perform protocol-dependent initialization for this AlternatingBitProtocol.
doInit() - Method in class RDTProtocol
doInit() is invoked to perform protocol-dependent initialization for this RDTProtocol.
doTask(Packet) - Method in interface TimingTask
tsk.doTask() does the work required to perform tsk.
doTest(int[]) - Method in class TimerFactoryTest
 

G

get() - Method in class IntQueue
q.get() returns the current item of q.
get() - Method in class PacketQueue
q.get() returns the current item of q.
getCopy() - Method in class Packet
pkt.getCopy() returns a clone of pkt.
getCount() - Method in class IntQueue
q.getCount() the number of items in q.
getCount() - Method in class PacketQueue
q.getCount() the number of items in q.
getDestination() - Method in class Packet
pkt.getDestination() returns the destination TCPEntity of pkt.
getIdentificationNumber() - Method in class Packet
pkt.getIdentificationNumber() returns the identification number of pkt.
getName() - Method in class TCPEntity.Context
cntxt.getName() returns the name of the TCPEntity that created this Context.
getPacket() - Method in class RDTTimer
tmr.getPacket() returns the packet that tmr times acknowlegements for.
getReceivedMessage() - Method in class TCPEntity
tcpe.getReceivedMessage() returns the message received by tcpe.
getReliability() - Static method in class Internet
Internet.getReliability() returns the probability that a Packet gets delivered in the Internet.
getRoundTripTime() - Static method in class Internet
Internet.getRoundTripTime() returns the average round-trip time for the Internet.
getSequenceNumber() - Method in class Packet
pkt.getSequenceNumber() returns the sequence number of pkt.
getSource() - Method in class Packet
pkt.getSource() returns the source TCPEntity of pkt.
getType() - Method in class Packet
pkt.getType() returns the type of pkt.

H

handleNewSegment(int) - Method in class AlternatingBitProtocol
handleNewSegment(id) is invoked to handle a new segment with identification number id.
handleNewSegment(int) - Method in class RDTProtocol
rdtp.handleNewSegment(id) is invoked to get rdtp to handle a new segment with identification number id.
handleReceivedAck(Packet) - Method in class AlternatingBitProtocol
rdtp.handleReceivedAck(pkt) is invoked to handle a ACK_TYPE packet received from its TCPEntity's connection partner.
handleReceivedAck(Packet) - Method in class RDTProtocol
rdtp.handleReceivedAck(pkt) is invoked to get rdtp to handle a ACK_TYPE packet received from its TCPEntity's connection partner.
handleReceivedClose(Packet) - Method in class RDTProtocol
rdtp.handleReceivedClose(pkt) is invoked to get rdtp to handle a CLOSE_TYPE packet received from its TCPEntity's connection partner.
handleReceivedData(Packet) - Method in class AlternatingBitProtocol
handleReceivedData(pkt) is invoked to handle a DATA_TYPE packet received from its TCPEntity's connection partner.
handleReceivedData(Packet) - Method in class RDTProtocol
rdtp.handleReceivedData(pkt) is invoked to get rdtp to handle a DATA_TYPE packet received from its TCPEntity's connection partner.
handleReceivedNack(Packet) - Method in class RDTProtocol
rdtp.handleReceivedNack(pkt) is invoked to get rdtp to handle a NACK_TYPE packet received from its TCPEntity's connection partner.
handleTimedOutPacket(Packet) - Method in class AlternatingBitProtocol
rdtp.handleTimedOutPacket(pkt) is invoked to handle a packet acknowledgement timeout for pkt.
handleTimedOutPacket(Packet) - Method in class RDTProtocol
rdtp.handleTimedOutPacket(pkt) is invoked to get rdtp to handle a packet acknowledgement timeout for pkt.

I

initialize(TCPEntity.Context) - Method in class RDTProtocol
rdtp.initialize(cntxt) is invoked when a connection is set up using rdtp.
initiateDisconnect() - Method in class RDTProtocol
rdtp.initiateDisconnect() is invoked to get rdtp to initate a disconnect sequence.
Internet - Class in <Unnamed>
The Internet class provides delivery of Packet objects between TCPEntity objects.
Internet() - Constructor for class Internet
 
IntQueue - Class in <Unnamed>
A IntQueue holds a sequence of int objects and provides access to them in the order that they were added to the sequence.
IntQueue() - Constructor for class IntQueue
new IntQueue() returns a new, empty queue for ints.

L

log(String) - Static method in class Logger
Logger.log(typ) logs a message of type typ.
log(String, Packet) - Static method in class Logger
Logger.log(typ, pkt) logs a message of type typ about Packet pkt.
Logger - Class in <Unnamed>
The Logger class provides logging for the reliable data transfer simulation.
Logger() - Constructor for class Logger
 

M

main(String[]) - Static method in class RDTTest
The main program tests an RDTProtocol by constructing two TCPEntities named "S" and "R", setting up a connection between them, and sending segmentCount segments from the "S" to "R".
main(String[]) - Static method in class TimerFactoryTest
 

N

NACK_TYPE - Static variable in class Packet
Packet.NACK_TYPE is the type for negative acknowledgement packets.

P

Packet - Class in <Unnamed>
A Packet is a protocol data unit used at the interface between a TCPEntity and an Internet.
Packet(TCPEntity, TCPEntity) - Constructor for class Packet
new Packet(src, dest) returns a new Packet.
PacketQueue - Class in <Unnamed>
A PacketQueue holds a sequence of Packet objects and provides access to them in the order that they were added to the sequence.
PacketQueue() - Constructor for class PacketQueue
new PacketQueue() returns a new, empty queue for Packets.
printConfiguration() - Static method in class Internet
Internet.printConfiguration() prints the configuration parameters for the Internet.
println() - Static method in class Logger
Logger.println() adds a blank line to the log.

R

RDTProtocol - Class in <Unnamed>
An RDTProtocol implements a reliable data transfer protocol on behalf of a TCP connection thread in the Transport layer.
RDTProtocol() - Constructor for class RDTProtocol
 
RDTTest - Class in <Unnamed>
Class RDTTest defines a main method for running the network simulation using an RDTProtocol as a reliable data transfer protocol.
RDTTest() - Constructor for class RDTTest
 
RDTTimer - Class in <Unnamed>
An RDTTimer schedules a timeout task for a packet to be executed in the future.
RDTTimer() - Constructor for class RDTTimer
 
reassemble(int) - Method in class RDTProtocol
reassemble(id) sends id to the reassembler.
reassemble(int) - Method in class TCPEntity.Context
cntxt.reassemble(id) sends the segment id to the reassembler of this TCPEntity.
receivePacket(Packet) - Method in class TCPEntity
tcpe.receivePacket(pkt) is invoked to get tcpe to handle a packet from its connection partner.
receiver - Static variable in class RDTTest
 
remove() - Method in class IntQueue
q.remove() removes the current item of q.
remove() - Method in class PacketQueue
q.remove() removes the current item of q.
run() - Method in class TCPEntity
Do not invoke this method externally - it is automatically invoked at the end of the setUp() method.

S

segmentCount - Static variable in class RDTTest
segmentCount is the number of segments to to send across the connection.
send(Packet) - Static method in class Internet
Internet.send(pkt) attempts delivery of pkt to its destination.
send(Packet) - Method in class RDTProtocol
send(pkt) sends pkt to the receiving end of the connection.
sendData(int) - Method in class TCPEntity
tcpe.sendData(id) sends a new data packet with identification number id from tcpe to its communication partner.
sender - Static variable in class RDTTest
 
setAcceptingNewSegments(boolean) - Method in class RDTProtocol
setAcceptingNewSegments(acc) informs the TCPEntity whether or not this RDTProtocol is accepting new segments.
setAcceptingNewSegments(boolean) - Method in class TCPEntity.Context
cntxt.setAcceptingNewSegments(ans) allows this TCPEntity to schedule new segment tasks if ans is true.
setIdentificationNumber(int) - Method in class Packet
pkt.setIdentificationNumber(id) sets the identification number of pkt to id.
setPacket(Packet) - Method in class RDTTimer
tmr.setPacket(pkt) sets the packet that tmr times acknowlegements for to pkt.
setPendingAcknowledgements(boolean) - Method in class RDTProtocol
setPendingAcknowledgements(pa) informs the TCPEntity whether or not this RDTProtocol has packets that have been sent but not yet acknowledged.
setPendingAcknowledgements(boolean) - Method in class TCPEntity.Context
cntxt.setPendingAcknowledgements(pa) notifies this TCPEntity that its protocol has packets that have been sent but not yet acknowledged.
setReliability(double) - Static method in class Internet
Internet.setReliability(rel) sets the probability that a Packet gets delivered in the Internet to rel.
setRoundTripTimes(int, int) - Static method in class Internet
Internet.setRoundTripTimes(min, max) sets the minimum and maximum round-trip time for the Internet to min and max.
setSeed(long) - Static method in class Internet
Internet.setSeed(sd) sets the seed for the random number generator used in the Internet to sd.
setSequenceNumber(int) - Method in class Packet
pkt.setSequenceNumber(seq) sets the sequence number of pkt to seq.
setType(String) - Method in class Packet
pkt.setType(typ) sets the type of pkt to typ.
setUp(TCPEntity, RDTProtocol) - Method in class TCPEntity
tcpe.setUp(prtnr, proto) sets up tcpe for communication with prtnr using the reliable data transfer protocol proto.
start() - Static method in class Logger
Logger.start() initializes Logger.
start() - Method in class RDTTimer
tmr.start() sets the scheduling time for tmr to the current time plus tmr's delay.
start(long) - Method in class RDTTimer
tmr.start(del) sets the scheduling time for tmr to the current time plus del.
start() - Method in class TimerFactory.Timer
tmr.start() sets the scheduled time for tmr's task to the current time plus tmr's delay.
start(long) - Method in class TimerFactory.Timer
tmr.start(del) sets the scheduled time for tmr's task to the current time plus del.
stop() - Method in class RDTTimer
tmr.stop() cancels tmr's scheduling time.
stop() - Method in class TimerFactory.Timer
tmr.stop() puts tmr in the stopped state.

T

TCPEntity - Class in <Unnamed>
A TCPEntity represents a TCP connection thread in the Transport layer.
TCPEntity(String) - Constructor for class TCPEntity
new TCPEntity(nm) returns a new TCPEntity named nm.
TCPEntity.Context - Class in <Unnamed>
A Context is created by a TCPEntity and passed to its RDTProtocol during set up of the TCPEntity.
TCPEntity.Context() - Constructor for class TCPEntity.Context
 
terminate() - Method in class RDTProtocol
terminate() terminates the thread used by this RDTProtocol.
terminate() - Method in class TCPEntity.Context
cntxt.terminate() terminates the execution of the thread created by this TCPEntity.
testProtocol() - Static method in class RDTTest
 
TimerFactory - Class in <Unnamed>
A TimerFactory is a factory for RDTTimer objects.
TimerFactory(String) - Constructor for class TimerFactory
TimerFactory(nm) returns an empty TimerFactory with name nm.
TimerFactory.Timer - Class in <Unnamed>
A TimerFactory.Timer times tasks that need to be performed at a later time.
TimerFactory.Timer(long, TimingTask) - Constructor for class TimerFactory.Timer
new Timer(del, tsk) returns a new Timer that performs task tsk.
TimerFactoryTest - Class in <Unnamed>
 
TimerFactoryTest() - Constructor for class TimerFactoryTest
 
TimingTask - Interface in <Unnamed>
A TimingTask represents a task that needs to be performed at a later time with a packet.
toString() - Method in class Packet
pkt.toString() returns a String describing pkt.
toString() - Method in class RDTProtocol
rdtp.toString() returns the name of rdtp, which is derived from its TCPEntity's name.
toString() - Method in class TCPEntity
tcpe.toString() returns the name of tcpe.
toString() - Method in class TimerFactory.Timer
tmr.toString() returns a String of the form name"-Timer-"id where name is the name of the TimerFactory that created tmr and id is the identification number of tmr.
toString() - Method in class TimerFactory
tq.toString() returns the name of tq.

W

waitUntilStopped() - Method in class TimerFactory
tq.waitUntilStopped() blocks until all timers are stopped.

A C D G H I L M N P R S T W