UDP Programming, Computer Networking

I have a larget text file of 1MB, how do i break down into chunks of packets to send over UDP?

byte b[]=new byte[1024];
FileInputStream f=new FileInputStream("input.txt");
DatagramSocket dsoc=new DatagramSocket(2000);
int i=0;
while(f.available()!=0)
{
b[i]=(byte)f.read();
i++;
}
f.close();
dsoc.send(new DatagramPacket(b,i,InetAddress.getLocalHost(),1000));

this doesnt seems to work
Posted Date: 11/12/2012 12:21:32 AM | Location : Singapore







Related Discussions:- UDP Programming, Assignment Help, Ask Question on UDP Programming, Get Answer, Expert's Help, UDP Programming Discussions

Write discussion on UDP Programming
Your posts are moderated
Related Questions
Hi, i am a college student doing a report on wireless broadband. I needed to know user requirements of user groups ie: Home user Small Medium Large Businesses Things like w

A. Current setting A new bank has its headquarters located in City A. Recently, the bank has opened its first branch in City B, and its data centre in City C. The three cities a

Explain clustering support Clustering support refers to the ability of a network operating system to link multiple servers in a fault-tolerant group. The main purpose of this i

Normal 0 false false false EN-IN X-NONE X-NONE

TYPES OF PARALLEL PROGRAMMING There are several parallel programming models in common use. Some of these are: Message Passing; Data Parallel programming; Shared

today, what is the most common or mostly encountered problem in terms of database management system?

Describe how EIGRP finds its successor and feasible successor?

Question: a) Describe the triangular delivery and two crossing problem that appears in Mobile IP. b) Discovery, Registration and Tunneling are three basic capabilities of Mo

Discuss about the Hypertext The hypertext allows for the integration of text, graphics, audio and video on a webpate. This can make it very easy to browse and very exciting to