public Socket accept() method are commonly used in ServerSocket class - Java

Q.  Which methods are commonly used in ServerSocket class?
- Published on 15 Jul 15

a. public OutputStream getOutputStream()
b. public Socket accept()
c. public synchronized void close()
d. None of the above

ANSWER: public Socket accept()
 

    Discussion

  • Prajakta Pandit   -Posted on 15 Dec 15

    - public Socket accept() methods are commonly used in ServerSocket class.

    - This class implements the server sockets.

    - It performs some operation based on that request and then possibly returns a result to the requester.

    - A server socket waits for the requests to come in over the network.

Post your comment / Share knowledge


Enter the code shown above:
 
(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)