< prev index next >
jdk/src/java.base/share/classes/java/net/SocketImpl.java
Print this page
*** 371,381 ****
* @throws UnsupportedOperationException if the SocketImpl does not
* support the option
*
* @throws IOException if an I/O error occurs, or if the socket is closed.
*
! * @since 1.9
*/
protected <T> void setOption(SocketOption<T> name, T value) throws IOException {
if (name == StandardSocketOptions.SO_KEEPALIVE &&
(getSocket() != null)) {
setOption(SocketOptions.SO_KEEPALIVE, value);
--- 371,381 ----
* @throws UnsupportedOperationException if the SocketImpl does not
* support the option
*
* @throws IOException if an I/O error occurs, or if the socket is closed.
*
! * @since 9
*/
protected <T> void setOption(SocketOption<T> name, T value) throws IOException {
if (name == StandardSocketOptions.SO_KEEPALIVE &&
(getSocket() != null)) {
setOption(SocketOptions.SO_KEEPALIVE, value);
*** 410,420 ****
* @throws UnsupportedOperationException if the SocketImpl does not
* support the option.
*
* @throws IOException if an I/O error occurs, or if the socket is closed.
*
! * @since 1.9
*/
@SuppressWarnings("unchecked")
protected <T> T getOption(SocketOption<T> name) throws IOException {
if (name == StandardSocketOptions.SO_KEEPALIVE &&
(getSocket() != null)) {
--- 410,420 ----
* @throws UnsupportedOperationException if the SocketImpl does not
* support the option.
*
* @throws IOException if an I/O error occurs, or if the socket is closed.
*
! * @since 9
*/
@SuppressWarnings("unchecked")
protected <T> T getOption(SocketOption<T> name) throws IOException {
if (name == StandardSocketOptions.SO_KEEPALIVE &&
(getSocket() != null)) {
< prev index next >