ServerSocket GetReceiveBufferSize() Example

Gets the value of the SO_RCVBUF option for this ServerSocket,


ServerSocketclass GetReceiveBufferSize() method example. This example shows you how to use GetReceiveBufferSize() method.This method Gets the value of the SO_RCVBUF option for this ServerSocket,

Here is the code:-

/**
 * @Program that Gets the value of the SO_RCVBUF option for this ServerSocket
 * GetReceiveBufferSize.java 
 * Author:-RoseIndia Team
 * Date:-21-jun-2008
 */
import java.net.*;

public class GetReceiveBufferSize {

    public static void main(String[] argsthrows Exception {
        InetAddress i = InetAddress.getByName("girish-desktop");
        ServerSocket ss = new ServerSocket(80801, i);
        System.out.println("RCVBUF option for this ServerSocket is: " + ss.getReceiveBufferSize());
    }
}

Output of the program:-
 RCVBUF option for this ServerSocket is: 43690

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

HOME | COPYRIGHT | CONTACT US