• Post Reply Bookmark Topic Watch Topic
  • New Topic

can anyone help me with this problem

 
swathi mpeddi
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Write a Java code segment (not a complete program) to open a datagram socket for receiving a datagram of up to 1000 bytes, timing out in 5 seconds. If a timeout happens, the message "timed out" should be displayed on the screen.

What happens if the timeout is set to 0?
 
Tim Holloway
Bartender
Posts: 18413
58
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try it and see!

Then read the javadocs.
 
Nathan Pruett
Bartender
Posts: 4121
IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moving to Sockets and Internet Protocols forum...
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!