Mercurial Hosting > luan
diff src/org/eclipse/jetty/io/JBuffer.java @ 1051:1ab2dd0a7db5
remove JBuffer.get(int)
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Tue, 08 Nov 2016 00:18:45 -0700 |
parents | 5ef954fad97b |
children | 4a2489f1d5fe |
line wrap: on
line diff
--- a/src/org/eclipse/jetty/io/JBuffer.java Mon Nov 07 23:49:41 2016 -0700 +++ b/src/org/eclipse/jetty/io/JBuffer.java Tue Nov 08 00:18:45 2016 -0700 @@ -90,14 +90,6 @@ } - public JBuffer get(int length) { - ByteBuffer dup = bb.duplicate(); - int end = bb.position()+length; - dup.limit(end); - bb.position(end); - return new JBuffer(dup); - } - public int get(byte[] b, int offset, int length) { int remaining = bb.remaining(); if( remaining == 0 ) @@ -151,10 +143,9 @@ bb.limit(putIndex); } - public int skip(int n) { + public void skip(int n) { if (remaining() < n) n = remaining(); bb.position(bb.position() + n); - return n; } public int readFrom(InputStream in,int max) throws IOException {