In my application, there's a module that uses ServerSocket
to listen for incoming TCP connections. When I switched a client to use UDP, I expected to receive data anyway, but I was wrong. When I looked at the documentation, however, I couldn't find any config option to set up the socket for UDP. Do I have to use a different class?
Use DatagramSocket. For a tutorial, look here http://download.oracle.com/javase/tutorial/networking/datagrams/index.html
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With