Self-Review Exercises
-
28.1 Fill in the blanks in each of the following statements:
Exception occurs when an input/output error occurs when closing a socket.
Exception occurs when a hostname indicated by a client cannot be resolved to an address.
If a
DatagramSocketconstructor fails to set up aDatagramSocketproperly, an exception of type occurs.Many of Java’s networking classes are contained in package .
Class binds the application to a port for datagram transmission.
An object of class contains an IP address.
The two types of sockets we discussed in this chapter are and .
MethodgetLocalHostreturns a(n) object containing ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access