Socket getReceiveBufferSize Example

Socket class getReceiveBufferSize example. This example shows you how to use getReceiveBufferSize method.


Socket class getReceiveBufferSize example. public int getReceiveBufferSize() throws SocketException Gets the value of the SO_RCVBUF option for this Socket, that is the buffer size used by the platform for input on this Socket

Here is the code
/*
 * @ # GetReceiveBufferSize.java
 * A class repersenting use to getReceiveBufferSize method 
 * of NumberFormat class in java.text package
 * version 17 June 2008
 * author Rose India 
 */

import java.net.*;

public class GetReceiveBufferSize {

    public static void main(String args[]) throws Exception {

        Socket socket = new Socket();

        //Connects this socket to the server.
        socket.connect(new InetSocketAddress("192.168.10.211"8080));

        System.out.println(socket.getReceiveBufferSize());

        //close socket
        socket.close();
    }
}

Output
43690

Post Comment
Name:
E-mail:
Contact no :
Comments:
  Refresh Image
Verify Image:
 
 
Your Comment's
 
 
 

HOME | COPYRIGHT | CONTACT US