**_All there is to do is to complete the [url removed, login to view] following these instructions._**
The constructor is incomplete. I have just listed the parameters and set simulatorto supervisorto permit calling the public method Sendin RoutSim. ***You will have to assign the values of some of the parameters to the private data members.*** In Java, One array can be assigned directly to another array, but they are really the same array going by two names. This is the same as passing an array as a parameter in C++. For example, you can do the following.
They will both be the names for the same array, but that will not cause any problems. You can take that one step further.
You now have three names for the same array. If you do this correctly, that will not matter. ***You will have to allocate and assign initial values to the array costs, which is the distance table. It has already been declared. When you are done with initialization, create a Packetfor each neighbor with Packet's constructor, and send it to each of them with simulator.Send. I have included a function IsLinkto determine whether or not a given node is actually a neighbor. Use a forstatement to loop through all nodes, and use IsLinkto decide if you want to create a Packetand send it. Leave the call to Printat the end of the constructor.***
***In Update, you must update the table based on what you will find in thePacket. Update each value in the column for the source of thePacket, but do not put any value greater than INFin the table. The function [url removed, login to view](x, y), which returns the smaller of xand y, may be helpful. Declare and allocate an array to hold the new minimum values for each row. Fill it with the appropriate values. If the array is the same as minCosts, do nothing. If the two arrays are different, assign the new array to minCosts, and send a packet to each of the neighbors informing them of you new minimal costs. RoutSimwill print out the new table.
Write any private member functions in the class Nodethat you want.
You might find the file "[url removed, login to view]" attached to the previous topic helpful since it was produced with the same data.
The code must be clearly commented so that a beginner can understand the program.
**Additional important information is attached including the program! The actual program has been written already and no changes should be made to any other files other than [url removed, login to view] (simply complete [url removed, login to view]).**
1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.
2) Deliverables must be in ready-to-run condition, as follows (depending on the nature of the deliverables):
a) For web sites or other server-side deliverables intended to only ever exist in one place in the Buyer's environment--Deliverables must be installed by the Seller in ready-to-run condition in the Buyer's environment.
b) For all others including desktop software or software the buyer intends to distribute: A software installation package that will install the software in ready-to-run condition on the platform(s) specified in this bid request.
3) All deliverables will be considered "work made for hire" under U.S. Copyright law. Buyer will receive exclusive and complete copyrights to all work purchased. (No GPL, GNU, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site per the coder's Seller Legal Agreement).