1142 Networking: Streams-Based Sockets and Datagrams Chapter 22 (Yahoo web space)
1142 Networking: Streams-Based Sockets and Datagrams Chapter 22 network address server port number networking as file I/O socket NetworkStream class socket-based communications OpenRead method of class WebClient Socket class OpenWrite method of class WebClient spawning packet Start method of class TcpListener pool of threads stream port number stream socket protocol streams-based transmission Read method of class NetworkStream system service ReadByte method of class NetworkStream System.Net namespace reading a file on a Web server System.Net.Sockets namespace ReadString method of class BinaryReaderTcpClient class receive a connection TcpListener class receive data from a server telephone system Receive method of class Socket Thread class Receive method of class UdpClient Transmission Control Protocol (TCP) ReceiveFrom method of class Socket UdpClient class send data to a server User Datagram Protocol (UDP) Send method of class Socket Web server Send method of class UdpClient WebClient class SendTo method of class Socket Write method of class BinaryWriter server Write method of class NetworkStream server Internet address WriteByte method of class NetworkStream SELF-REVIEW EXERCISES 22.1 State whether each of the following is true or false. If false, explain why. a) UDP is a connection-oriented protocol. b) With stream sockets, a process establishes a connection to another process. c) Datagram-packet transmission over a network is reliable packets are guaranteed to arrive in sequence. d) Most of the time TCP protocol is preferred over the UDP protocol. e) Each TcpListener can accept only one connection. f) A TcpListener can listen for connections at more than one port at a time. g) A UdpClient can send information only to one particular port. h) Packets sent via a UDP connection are sent only once. i) Clients need to know the port number at which the server is waiting for connections. 22.2 Fill in the blanks in each of the following statements: a) Many of C# s networking classes are contained in namespaces and . b) Class is used for unreliable but fast datagram transmission. c) An object of class represents an Internet Protocol (IP) address. d) The two types of sockets we discussed in this chapter are sockets and sockets. e) The acronym TCP stands for . f) Class listens for connections from clients. g) Class connects to servers. h) Class provides access to stream data on a network.
Note: If you are looking for best quality webspace to host and run your tomcat application check Vision shared web hosting services