src/java.base/share/classes/java/nio/channels/ReadableByteChannel.java
changeset 59227 46084917fde7
parent 47216 71c04702a3d5
equal deleted inserted replaced
59226:a0f39cc47387 59227:46084917fde7
     1 /*
     1 /*
     2  * Copyright (c) 2000, 2001, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2000, 2019, 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
    82      *         The buffer into which bytes are to be transferred
    82      *         The buffer into which bytes are to be transferred
    83      *
    83      *
    84      * @return  The number of bytes read, possibly zero, or {@code -1} if the
    84      * @return  The number of bytes read, possibly zero, or {@code -1} if the
    85      *          channel has reached end-of-stream
    85      *          channel has reached end-of-stream
    86      *
    86      *
       
    87      * @throws  IllegalArgumentException
       
    88      *          If the buffer is read-only
       
    89      *
    87      * @throws  NonReadableChannelException
    90      * @throws  NonReadableChannelException
    88      *          If this channel was not opened for reading
    91      *          If this channel was not opened for reading
    89      *
    92      *
    90      * @throws  ClosedChannelException
    93      * @throws  ClosedChannelException
    91      *          If this channel is closed
    94      *          If this channel is closed