Skip to content

Commit

Permalink
Merge latest openjdk
Browse files Browse the repository at this point in the history
  • Loading branch information
j9build committed Jul 25, 2024
2 parents 62186fe + 7b66ba3 commit b3718ec
Show file tree
Hide file tree
Showing 20 changed files with 787 additions and 301 deletions.
22 changes: 14 additions & 8 deletions src/java.base/share/classes/java/lang/Process.java
Original file line number Diff line number Diff line change
Expand Up @@ -442,10 +442,13 @@ public final BufferedWriter outputWriter(Charset charset) {
* terminated and the timeout value is less than, or equal to, zero, then
* this method returns immediately with the value {@code false}.
*
* <p>The default implementation of this method polls the {@code exitValue}
* to check if the process has terminated. Concrete implementations of this
* class are strongly encouraged to override this method with a more
* efficient implementation.
* @implSpec
* The default implementation of this method polls the {@code exitValue}
* to check if the process has terminated.
*
* @implNote
* Concrete implementations of this class are strongly encouraged to
* override this method with a more efficient implementation.
*
* @param timeout the maximum time to wait
* @param unit the time unit of the {@code timeout} argument
Expand Down Expand Up @@ -486,10 +489,13 @@ public boolean waitFor(long timeout, TimeUnit unit)
* terminated and the duration is not positive, then
* this method returns immediately with the value {@code false}.
*
* <p>The default implementation of this method polls the {@code exitValue}
* to check if the process has terminated. Concrete implementations of this
* class are strongly encouraged to override this method with a more
* efficient implementation.
* @implSpec
* The default implementation of this method polls the {@code exitValue}
* to check if the process has terminated.
*
* @implNote
* Concrete implementations of this class are strongly encouraged to
* override this method with a more efficient implementation.
*
* @param duration the maximum duration to wait; if not positive,
* this method returns immediately.
Expand Down
31 changes: 17 additions & 14 deletions src/java.base/share/classes/java/net/ServerSocket.java
Original file line number Diff line number Diff line change
Expand Up @@ -328,8 +328,8 @@ private SocketImpl getImpl() throws SocketException {
* an ephemeral port and a valid local address to bind the socket.
*
* @param endpoint The IP address and port number to bind to.
* @throws IOException if the bind operation fails, or if the socket
* is already bound.
* @throws IOException if the bind operation fails, the socket
* is already bound or the socket is closed.
* @throws SecurityException if a {@code SecurityManager} is present and
* its {@code checkListen} method doesn't allow the operation.
* @throws IllegalArgumentException if endpoint is a
Expand Down Expand Up @@ -357,8 +357,8 @@ public void bind(SocketAddress endpoint) throws IOException {
* @param endpoint The IP address and port number to bind to.
* @param backlog requested maximum length of the queue of
* incoming connections.
* @throws IOException if the bind operation fails, or if the socket
* is already bound.
* @throws IOException if the bind operation fails, the socket
* is already bound or the socket is closed.
* @throws SecurityException if a {@code SecurityManager} is present and
* its {@code checkListen} method doesn't allow the operation.
* @throws IllegalArgumentException if endpoint is a
Expand Down Expand Up @@ -518,7 +518,7 @@ public SocketAddress getLocalSocketAddress() {
* client socket implementation factory}, if one has been set.
*
* @throws IOException if an I/O error occurs when waiting for a
* connection.
* connection, the socket is not bound or the socket is closed.
* @throws SecurityException if a security manager exists and its
* {@code checkAccept} method doesn't allow the operation.
* @throws SocketTimeoutException if a timeout was previously set with setSoTimeout and
Expand Down Expand Up @@ -736,6 +736,9 @@ private void ensureCompatible(SocketImpl si) throws IOException {
* <p> If this socket has an associated channel then the channel is closed
* as well.
*
* <p> Once closed, several of the methods defined by this class will throw
* an exception if invoked on the closed socket.
*
* @throws IOException if an I/O error occurs when closing the socket.
*/
public void close() throws IOException {
Expand Down Expand Up @@ -806,8 +809,8 @@ public boolean isClosed() {
* operation to have effect.
*
* @param timeout the specified timeout, in milliseconds
* @throws SocketException if there is an error in the underlying protocol,
* such as a TCP error
* @throws SocketException if there is an error in the underlying protocol,
* such as a TCP error, or the socket is closed.
* @throws IllegalArgumentException if {@code timeout} is negative
* @since 1.1
* @see #getSoTimeout()
Expand All @@ -824,7 +827,7 @@ public void setSoTimeout(int timeout) throws SocketException {
* Retrieve setting for {@link SocketOptions#SO_TIMEOUT SO_TIMEOUT}.
* 0 returns implies that the option is disabled (i.e., timeout of infinity).
* @return the {@link SocketOptions#SO_TIMEOUT SO_TIMEOUT} value
* @throws IOException if an I/O error occurs
* @throws IOException if an I/O error occurs or the socket is closed.
* @since 1.1
* @see #setSoTimeout(int)
*/
Expand Down Expand Up @@ -887,8 +890,8 @@ public void setReuseAddress(boolean on) throws SocketException {
*
* @return a {@code boolean} indicating whether or not
* {@code SO_REUSEADDR} is enabled.
* @throws SocketException if there is an error
* in the underlying protocol, such as a TCP error.
* @throws SocketException if there is an error in the underlying protocol, such as a TCP error,
* or the socket is closed.
* @since 1.4
* @see #setReuseAddress(boolean)
*/
Expand Down Expand Up @@ -1001,8 +1004,8 @@ public static synchronized void setSocketFactory(SocketImplFactory fac) throws I
* requested value but the TCP receive window in sockets accepted from
* this ServerSocket will be no larger than 64K bytes.
*
* @throws SocketException if there is an error
* in the underlying protocol, such as a TCP error.
* @throws SocketException if there is an error in the underlying protocol,
* such as a TCP error, or the socket is closed.
*
* @param size the size to which to set the receive buffer
* size. This value must be greater than 0.
Expand All @@ -1029,8 +1032,8 @@ public void setReceiveBufferSize(int size) throws SocketException {
* <p>Note, the value actually set in the accepted socket is determined by
* calling {@link Socket#getReceiveBufferSize()}.
* @return the value of the {@code SO_RCVBUF} option for this {@code Socket}.
* @throws SocketException if there is an error
* in the underlying protocol, such as a TCP error.
* @throws SocketException if there is an error in the underlying protocol,
* such as a TCP error, or the socket is closed.
* @see #setReceiveBufferSize(int)
* @since 1.4
*/
Expand Down
Loading

0 comments on commit b3718ec

Please sign in to comment.