Self-Review Exercises
28.1 Fill in the blanks in each of the following statements:
a) Exception __________ occurs when an input/output error occurs when closing a socket.
b) Exception __________ occurs when a hostname indicated by a client cannot be resolved to an address.
c) If a DatagramSocket constructor fails to set up a DatagramSocket properly, an exception of type __________ occurs.
d) Many of Java’s networking classes are contained in package __________.
e) Class __________ binds the application to a port for datagram transmission.
f) An object of class __________ contains an IP address.
g) The two types of sockets we discussed in this chapter are __________ and __________.
h) Method getLocalHost returns 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