jdk/src/java.base/share/classes/java/net/SocketOptions.java
changeset 36115 0676e37a0b9c
parent 33672 971eeb07166a
child 45434 4582657c7260
equal deleted inserted replaced
36114:a5ed9456c9be 36115:0676e37a0b9c
     1 /*
     1 /*
     2  * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.  Oracle designates this
     7  * published by the Free Software Foundation.  Oracle designates this
   168      * Valid for: DatagramSocketImpl
   168      * Valid for: DatagramSocketImpl
   169      */
   169      */
   170 
   170 
   171     @Native public static final int SO_REUSEADDR = 0x04;
   171     @Native public static final int SO_REUSEADDR = 0x04;
   172 
   172 
       
   173     /** Sets SO_REUSEPORT for a socket. This option enables and disables
       
   174      *  the ability to have multiple sockets listen to the same address
       
   175      *  and port.
       
   176      * <P>
       
   177      * Valid for: SocketImpl, DatagramSocketImpl
       
   178      *
       
   179      * @since 9
       
   180      * @see StandardSocketOptions#SO_REUSEPORT
       
   181      */
       
   182     @Native public static final int SO_REUSEPORT = 0x0E;
       
   183 
   173     /**
   184     /**
   174      * Sets SO_BROADCAST for a socket. This option enables and disables
   185      * Sets SO_BROADCAST for a socket. This option enables and disables
   175      * the ability of the process to send broadcast messages. It is supported
   186      * the ability of the process to send broadcast messages. It is supported
   176      * for only datagram sockets and only on networks that support
   187      * for only datagram sockets and only on networks that support
   177      * the concept of a broadcast message (e.g. Ethernet, token ring, etc.),
   188      * the concept of a broadcast message (e.g. Ethernet, token ring, etc.),