+1
On 6/3/2016 3:15 PM, Brian Burkhalter wrote:
So if I make this change to the webrev
--- a/src/java.base/share/classes/java/io/InputStream.java
+++ b/src/java.base/share/classes/java/io/InputStream.java
@@ -333,8 +333,7 @@
*
* @param n the number of bytes to be skipped.
* @return the actual number of bytes skipped.
- * @throws IOException if an I/O error occurs, such as
attempting to
- * seek to a negative position in a seek-based implementation.
+ * @throws IOException if an I/O error occurs.
*/
public long skip(long n) throws IOException {
do we have consensus?
Thanks,
Brian
On Jun 3, 2016, at 11:34 AM, Pavel Rappo <pavel.ra...@oracle.com
<mailto:pavel.ra...@oracle.com>> wrote:
On 3 Jun 2016, at 19:30, Bernd Eckenfels <e...@zusammenkunft.net
<mailto:e...@zusammenkunft.net>> wrote:
It is unclear to me if this is really forbidden in the interface or in
any implementation. With FileInputStream skip(-5) works.
Don't mistake `seek` for `skip`. `skip` can be implemented using
`read`, but
may be using `seek`.
Here's the API point of view:
* If {@code n} is
* negative, the {@code skip} method for class {@code InputStream}
always
* returns 0, and no bytes are skipped. Subclasses may handle the
negative
* value differently.
Thanks,
-Pavel