Lines Matching refs:off

160      * them into <code>b</code> starting at index <code>off</code>.
172 * @param off the starting position within <code>b</code> to write to.
178 * @exception IndexOutOfBoundsException if <code>off</code> is
179 * negative, <code>len</code> is negative, or <code>off +
185 public abstract int read(byte[] b, int off, int len) throws IOException;
343 public void readFully(byte[] b, int off, int len) throws IOException {
344 // Fix 4430357 - if off + len < 0, overflow occurred
345 if (off < 0 || len < 0 || off + len > b.length || off + len < 0) {
347 ("off < 0 || len < 0 || off + len > b.length!");
351 int nbytes = read(b, off, len);
355 off += nbytes;
364 public void readFully(short[] s, int off, int len) throws IOException {
365 // Fix 4430357 - if off + len < 0, overflow occurred
366 if (off < 0 || len < 0 || off + len > s.length || off + len < 0) {
368 ("off < 0 || len < 0 || off + len > s.length!");
374 toShorts(byteBuf, s, off, nelts);
375 off += nelts;
380 public void readFully(char[] c, int off, int len) throws IOException {
381 // Fix 4430357 - if off + len < 0, overflow occurred
382 if (off < 0 || len < 0 || off + len > c.length || off + len < 0) {
384 ("off < 0 || len < 0 || off + len > c.length!");
390 toChars(byteBuf, c, off, nelts);
391 off += nelts;
396 public void readFully(int[] i, int off, int len) throws IOException {
397 // Fix 4430357 - if off + len < 0, overflow occurred
398 if (off < 0 || len < 0 || off + len > i.length || off + len < 0) {
400 ("off < 0 || len < 0 || off + len > i.length!");
406 toInts(byteBuf, i, off, nelts);
407 off += nelts;
412 public void readFully(long[] l, int off, int len) throws IOException {
413 // Fix 4430357 - if off + len < 0, overflow occurred
414 if (off < 0 || len < 0 || off + len > l.length || off + len < 0) {
416 ("off < 0 || len < 0 || off + len > l.length!");
422 toLongs(byteBuf, l, off, nelts);
423 off += nelts;
428 public void readFully(float[] f, int off, int len) throws IOException {
429 // Fix 4430357 - if off + len < 0, overflow occurred
430 if (off < 0 || len < 0 || off + len > f.length || off + len < 0) {
432 ("off < 0 || len < 0 || off + len > f.length!");
438 toFloats(byteBuf, f, off, nelts);
439 off += nelts;
444 public void readFully(double[] d, int off, int len) throws IOException {
445 // Fix 4430357 - if off + len < 0, overflow occurred
446 if (off < 0 || len < 0 || off + len > d.length || off + len < 0) {
448 ("off < 0 || len < 0 || off + len > d.length!");
454 toDoubles(byteBuf, d, off, nelts);
455 off += nelts;
460 private void toShorts(byte[] b, short[] s, int off, int len) {
466 s[off + j] = (short)((b0 << 8) | b1);
473 s[off + j] = (short)((b0 << 8) | b1);
479 private void toChars(byte[] b, char[] c, int off, int len) {
485 c[off + j] = (char)((b0 << 8) | b1);
492 c[off + j] = (char)((b0 << 8) | b1);
498 private void toInts(byte[] b, int[] i, int off, int len) {
506 i[off + j] = (b0 << 24) | (b1 << 16) | (b2 << 8) | b3;
515 i[off + j] = (b0 << 24) | (b1 << 16) | (b2 << 8) | b3;
521 private void toLongs(byte[] b, long[] l, int off, int len) {
537 l[off + j] = ((long)i0 << 32) | (i1 & 0xffffffffL);
554 l[off + j] = ((long)i0 << 32) | (i1 & 0xffffffffL);
560 private void toFloats(byte[] b, float[] f, int off, int len) {
569 f[off + j] = Float.intBitsToFloat(i);
579 f[off + j] = Float.intBitsToFloat(i);
585 private void toDoubles(byte[] b, double[] d, int off, int len) {
602 d[off + j] = Double.longBitsToDouble(l);
620 d[off + j] = Double.longBitsToDouble(l);