src/java.base/share/classes/java/nio/channels/spi/AbstractInterruptibleChannel.java
author alanb
Wed, 08 May 2019 08:15:04 +0100
changeset 54754 193a8f1a4f3b
parent 54620 13b67c1420b8
permissions -rw-r--r--
8223353: (ch) Change channel close implementation to not wait for I/O threads Reviewed-by: dfuchs, chegar
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     1
/*
54620
13b67c1420b8 8222774: (ch) Replace uses of stateLock and blockingLock with j.u.c. locks
alanb
parents: 52427
diff changeset
     2
 * Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     4
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
90ce3da70b43 Initial load
duke
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    10
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
90ce3da70b43 Initial load
duke
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
90ce3da70b43 Initial load
duke
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
90ce3da70b43 Initial load
duke
parents:
diff changeset
    15
 * accompanied this code).
90ce3da70b43 Initial load
duke
parents:
diff changeset
    16
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
90ce3da70b43 Initial load
duke
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    20
 *
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    23
 * questions.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    24
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    25
90ce3da70b43 Initial load
duke
parents:
diff changeset
    26
package java.nio.channels.spi;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    27
90ce3da70b43 Initial load
duke
parents:
diff changeset
    28
import java.io.IOException;
54620
13b67c1420b8 8222774: (ch) Replace uses of stateLock and blockingLock with j.u.c. locks
alanb
parents: 52427
diff changeset
    29
import java.nio.channels.AsynchronousCloseException;
13b67c1420b8 8222774: (ch) Replace uses of stateLock and blockingLock with j.u.c. locks
alanb
parents: 52427
diff changeset
    30
import java.nio.channels.Channel;
13b67c1420b8 8222774: (ch) Replace uses of stateLock and blockingLock with j.u.c. locks
alanb
parents: 52427
diff changeset
    31
import java.nio.channels.ClosedByInterruptException;
13b67c1420b8 8222774: (ch) Replace uses of stateLock and blockingLock with j.u.c. locks
alanb
parents: 52427
diff changeset
    32
import java.nio.channels.InterruptibleChannel;
13b67c1420b8 8222774: (ch) Replace uses of stateLock and blockingLock with j.u.c. locks
alanb
parents: 52427
diff changeset
    33
52427
3c6aa484536c 8211122: Reduce the number of internal classes made accessible to jdk.unsupported
mchung
parents: 49001
diff changeset
    34
import jdk.internal.access.SharedSecrets;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    35
import sun.nio.ch.Interruptible;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    36
90ce3da70b43 Initial load
duke
parents:
diff changeset
    37
90ce3da70b43 Initial load
duke
parents:
diff changeset
    38
/**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    39
 * Base implementation class for interruptible channels.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    40
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    41
 * <p> This class encapsulates the low-level machinery required to implement
90ce3da70b43 Initial load
duke
parents:
diff changeset
    42
 * the asynchronous closing and interruption of channels.  A concrete channel
90ce3da70b43 Initial load
duke
parents:
diff changeset
    43
 * class must invoke the {@link #begin begin} and {@link #end end} methods
90ce3da70b43 Initial load
duke
parents:
diff changeset
    44
 * before and after, respectively, invoking an I/O operation that might block
90ce3da70b43 Initial load
duke
parents:
diff changeset
    45
 * indefinitely.  In order to ensure that the {@link #end end} method is always
90ce3da70b43 Initial load
duke
parents:
diff changeset
    46
 * invoked, these methods should be used within a
32143
394ab6a6658d 8133459: replace <tt> tags (obsolete in html5) in java.nio docs
avstepan
parents: 27757
diff changeset
    47
 * {@code try}&nbsp;...&nbsp;{@code finally} block:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    48
 *
47004
b7e72fc752c9 8186684: Fix broken links in java.base API docs
jjg
parents: 34774
diff changeset
    49
 * <blockquote><pre id="be">
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    50
 * boolean completed = false;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    51
 * try {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    52
 *     begin();
90ce3da70b43 Initial load
duke
parents:
diff changeset
    53
 *     completed = ...;    // Perform blocking I/O operation
90ce3da70b43 Initial load
duke
parents:
diff changeset
    54
 *     return ...;         // Return result
90ce3da70b43 Initial load
duke
parents:
diff changeset
    55
 * } finally {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    56
 *     end(completed);
90ce3da70b43 Initial load
duke
parents:
diff changeset
    57
 * }</pre></blockquote>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    58
 *
32143
394ab6a6658d 8133459: replace <tt> tags (obsolete in html5) in java.nio docs
avstepan
parents: 27757
diff changeset
    59
 * <p> The {@code completed} argument to the {@link #end end} method tells
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    60
 * whether or not the I/O operation actually completed, that is, whether it had
90ce3da70b43 Initial load
duke
parents:
diff changeset
    61
 * any effect that would be visible to the invoker.  In the case of an
90ce3da70b43 Initial load
duke
parents:
diff changeset
    62
 * operation that reads bytes, for example, this argument should be
32143
394ab6a6658d 8133459: replace <tt> tags (obsolete in html5) in java.nio docs
avstepan
parents: 27757
diff changeset
    63
 * {@code true} if, and only if, some bytes were actually transferred into the
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    64
 * invoker's target buffer.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    65
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    66
 * <p> A concrete channel class must also implement the {@link
90ce3da70b43 Initial load
duke
parents:
diff changeset
    67
 * #implCloseChannel implCloseChannel} method in such a way that if it is
90ce3da70b43 Initial load
duke
parents:
diff changeset
    68
 * invoked while another thread is blocked in a native I/O operation upon the
90ce3da70b43 Initial load
duke
parents:
diff changeset
    69
 * channel then that operation will immediately return, either by throwing an
90ce3da70b43 Initial load
duke
parents:
diff changeset
    70
 * exception or by returning normally.  If a thread is interrupted or the
90ce3da70b43 Initial load
duke
parents:
diff changeset
    71
 * channel upon which it is blocked is asynchronously closed then the channel's
90ce3da70b43 Initial load
duke
parents:
diff changeset
    72
 * {@link #end end} method will throw the appropriate exception.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    73
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    74
 * <p> This class performs the synchronization required to implement the {@link
90ce3da70b43 Initial load
duke
parents:
diff changeset
    75
 * java.nio.channels.Channel} specification.  Implementations of the {@link
90ce3da70b43 Initial load
duke
parents:
diff changeset
    76
 * #implCloseChannel implCloseChannel} method need not synchronize against
90ce3da70b43 Initial load
duke
parents:
diff changeset
    77
 * other threads that might be attempting to close the channel.  </p>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    78
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    79
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    80
 * @author Mark Reinhold
90ce3da70b43 Initial load
duke
parents:
diff changeset
    81
 * @author JSR-51 Expert Group
90ce3da70b43 Initial load
duke
parents:
diff changeset
    82
 * @since 1.4
90ce3da70b43 Initial load
duke
parents:
diff changeset
    83
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    84
90ce3da70b43 Initial load
duke
parents:
diff changeset
    85
public abstract class AbstractInterruptibleChannel
90ce3da70b43 Initial load
duke
parents:
diff changeset
    86
    implements Channel, InterruptibleChannel
90ce3da70b43 Initial load
duke
parents:
diff changeset
    87
{
54754
193a8f1a4f3b 8223353: (ch) Change channel close implementation to not wait for I/O threads
alanb
parents: 54620
diff changeset
    88
    private final Object closeLock = new Object();
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 32834
diff changeset
    89
    private volatile boolean closed;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    90
90ce3da70b43 Initial load
duke
parents:
diff changeset
    91
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    92
     * Initializes a new instance of this class.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    93
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    94
    protected AbstractInterruptibleChannel() { }
90ce3da70b43 Initial load
duke
parents:
diff changeset
    95
90ce3da70b43 Initial load
duke
parents:
diff changeset
    96
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    97
     * Closes this channel.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    98
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    99
     * <p> If the channel has already been closed then this method returns
90ce3da70b43 Initial load
duke
parents:
diff changeset
   100
     * immediately.  Otherwise it marks the channel as closed and then invokes
90ce3da70b43 Initial load
duke
parents:
diff changeset
   101
     * the {@link #implCloseChannel implCloseChannel} method in order to
90ce3da70b43 Initial load
duke
parents:
diff changeset
   102
     * complete the close operation.  </p>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   103
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   104
     * @throws  IOException
90ce3da70b43 Initial load
duke
parents:
diff changeset
   105
     *          If an I/O error occurs
90ce3da70b43 Initial load
duke
parents:
diff changeset
   106
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   107
    public final void close() throws IOException {
54754
193a8f1a4f3b 8223353: (ch) Change channel close implementation to not wait for I/O threads
alanb
parents: 54620
diff changeset
   108
        synchronized (closeLock) {
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 32834
diff changeset
   109
            if (closed)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   110
                return;
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 32834
diff changeset
   111
            closed = true;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   112
            implCloseChannel();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   113
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   114
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   115
90ce3da70b43 Initial load
duke
parents:
diff changeset
   116
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   117
     * Closes this channel.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   118
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   119
     * <p> This method is invoked by the {@link #close close} method in order
90ce3da70b43 Initial load
duke
parents:
diff changeset
   120
     * to perform the actual work of closing the channel.  This method is only
90ce3da70b43 Initial load
duke
parents:
diff changeset
   121
     * invoked if the channel has not yet been closed, and it is never invoked
90ce3da70b43 Initial load
duke
parents:
diff changeset
   122
     * more than once.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   123
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   124
     * <p> An implementation of this method must arrange for any other thread
90ce3da70b43 Initial load
duke
parents:
diff changeset
   125
     * that is blocked in an I/O operation upon this channel to return
90ce3da70b43 Initial load
duke
parents:
diff changeset
   126
     * immediately, either by throwing an exception or by returning normally.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   127
     * </p>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   128
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   129
     * @throws  IOException
90ce3da70b43 Initial load
duke
parents:
diff changeset
   130
     *          If an I/O error occurs while closing the channel
90ce3da70b43 Initial load
duke
parents:
diff changeset
   131
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   132
    protected abstract void implCloseChannel() throws IOException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   133
90ce3da70b43 Initial load
duke
parents:
diff changeset
   134
    public final boolean isOpen() {
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 32834
diff changeset
   135
        return !closed;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   136
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   137
90ce3da70b43 Initial load
duke
parents:
diff changeset
   138
90ce3da70b43 Initial load
duke
parents:
diff changeset
   139
    // -- Interruption machinery --
90ce3da70b43 Initial load
duke
parents:
diff changeset
   140
90ce3da70b43 Initial load
duke
parents:
diff changeset
   141
    private Interruptible interruptor;
7177
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   142
    private volatile Thread interrupted;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   143
90ce3da70b43 Initial load
duke
parents:
diff changeset
   144
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   145
     * Marks the beginning of an I/O operation that might block indefinitely.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   146
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   147
     * <p> This method should be invoked in tandem with the {@link #end end}
32143
394ab6a6658d 8133459: replace <tt> tags (obsolete in html5) in java.nio docs
avstepan
parents: 27757
diff changeset
   148
     * method, using a {@code try}&nbsp;...&nbsp;{@code finally} block as
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   149
     * shown <a href="#be">above</a>, in order to implement asynchronous
90ce3da70b43 Initial load
duke
parents:
diff changeset
   150
     * closing and interruption for this channel.  </p>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   151
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   152
    protected final void begin() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   153
        if (interruptor == null) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   154
            interruptor = new Interruptible() {
7177
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   155
                    public void interrupt(Thread target) {
54754
193a8f1a4f3b 8223353: (ch) Change channel close implementation to not wait for I/O threads
alanb
parents: 54620
diff changeset
   156
                        synchronized (closeLock) {
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 32834
diff changeset
   157
                            if (closed)
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   158
                                return;
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 32834
diff changeset
   159
                            closed = true;
7177
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   160
                            interrupted = target;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   161
                            try {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   162
                                AbstractInterruptibleChannel.this.implCloseChannel();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   163
                            } catch (IOException x) { }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   164
                        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   165
                    }};
90ce3da70b43 Initial load
duke
parents:
diff changeset
   166
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   167
        blockedOn(interruptor);
7177
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   168
        Thread me = Thread.currentThread();
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   169
        if (me.isInterrupted())
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   170
            interruptor.interrupt(me);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   171
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   172
90ce3da70b43 Initial load
duke
parents:
diff changeset
   173
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   174
     * Marks the end of an I/O operation that might block indefinitely.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   175
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   176
     * <p> This method should be invoked in tandem with the {@link #begin
32143
394ab6a6658d 8133459: replace <tt> tags (obsolete in html5) in java.nio docs
avstepan
parents: 27757
diff changeset
   177
     * begin} method, using a {@code try}&nbsp;...&nbsp;{@code finally} block
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   178
     * as shown <a href="#be">above</a>, in order to implement asynchronous
90ce3da70b43 Initial load
duke
parents:
diff changeset
   179
     * closing and interruption for this channel.  </p>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   180
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   181
     * @param  completed
32143
394ab6a6658d 8133459: replace <tt> tags (obsolete in html5) in java.nio docs
avstepan
parents: 27757
diff changeset
   182
     *         {@code true} if, and only if, the I/O operation completed
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   183
     *         successfully, that is, had some effect that would be visible to
90ce3da70b43 Initial load
duke
parents:
diff changeset
   184
     *         the operation's invoker
90ce3da70b43 Initial load
duke
parents:
diff changeset
   185
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   186
     * @throws  AsynchronousCloseException
90ce3da70b43 Initial load
duke
parents:
diff changeset
   187
     *          If the channel was asynchronously closed
90ce3da70b43 Initial load
duke
parents:
diff changeset
   188
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   189
     * @throws  ClosedByInterruptException
90ce3da70b43 Initial load
duke
parents:
diff changeset
   190
     *          If the thread blocked in the I/O operation was interrupted
90ce3da70b43 Initial load
duke
parents:
diff changeset
   191
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   192
    protected final void end(boolean completed)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   193
        throws AsynchronousCloseException
90ce3da70b43 Initial load
duke
parents:
diff changeset
   194
    {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   195
        blockedOn(null);
7177
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   196
        Thread interrupted = this.interrupted;
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   197
        if (interrupted != null && interrupted == Thread.currentThread()) {
27757
0317e4973b42 8065720: (ch) AbstractInterruptibleChannel.end sets interrupted to null
alanb
parents: 25859
diff changeset
   198
            this.interrupted = null;
7177
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   199
            throw new ClosedByInterruptException();
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   200
        }
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 32834
diff changeset
   201
        if (!completed && closed)
7177
0113db4feebc 6979009: (fc) FileChannel.read() fails to throw ClosedByInterruptException
alanb
parents: 5506
diff changeset
   202
            throw new AsynchronousCloseException();
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   203
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   204
90ce3da70b43 Initial load
duke
parents:
diff changeset
   205
52427
3c6aa484536c 8211122: Reduce the number of internal classes made accessible to jdk.unsupported
mchung
parents: 49001
diff changeset
   206
    // -- jdk.internal.access.SharedSecrets --
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   207
    static void blockedOn(Interruptible intr) {         // package-private
49001
ce06058197a4 8198562: (ch) Separate blocking and non-blocking code paths (part 1)
alanb
parents: 47216
diff changeset
   208
        SharedSecrets.getJavaLangAccess().blockedOn(intr);
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   209
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   210
}