Home
last modified time | relevance | path

Searched refs:slice (Results 1 – 25 of 51) sorted by relevance

123

/libcore/luni/src/test/java/libcore/java/nio/
DBufferTest.java250 assertEquals(ByteOrder.BIG_ENDIAN, b.slice().order()); in testByteBufferByteOrder()
252 assertEquals(ByteOrder.BIG_ENDIAN, b.slice().order()); in testByteBufferByteOrder()
282 assertEquals(bo, b.slice().order()); in testCharBufferByteOrder()
286 assertEquals(bo, b.slice().order()); in testCharBufferByteOrder()
313 assertEquals(bo, b.slice().order()); in testDoubleBufferByteOrder()
317 assertEquals(bo, b.slice().order()); in testDoubleBufferByteOrder()
344 assertEquals(bo, b.slice().order()); in testFloatBufferByteOrder()
348 assertEquals(bo, b.slice().order()); in testFloatBufferByteOrder()
375 assertEquals(bo, b.slice().order()); in testIntBufferByteOrder()
379 assertEquals(bo, b.slice().order()); in testIntBufferByteOrder()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/
DSliceSliceDirectByteBufferTest.java25 buf = buf.slice(); in setUp()
27 buf = buf.slice(); in setUp()
DLongBufferTest.java578 LongBuffer slice = buf.slice(); in testSlice() local
579 assertEquals(buf.isReadOnly(), slice.isReadOnly()); in testSlice()
580 assertEquals(buf.isDirect(), slice.isDirect()); in testSlice()
581 assertEquals(buf.order(), slice.order()); in testSlice()
582 assertEquals(slice.position(), 0); in testSlice()
583 assertEquals(slice.limit(), buf.remaining()); in testSlice()
584 assertEquals(slice.capacity(), buf.remaining()); in testSlice()
586 slice.reset(); in testSlice()
593 if (!slice.isReadOnly()) { in testSlice()
594 loadTestData1(slice); in testSlice()
[all …]
DDoubleBufferTest.java595 DoubleBuffer slice = buf.slice();
596 assertEquals(buf.isReadOnly(), slice.isReadOnly());
597 assertEquals(buf.isDirect(), slice.isDirect());
598 assertEquals(buf.order(), slice.order());
599 assertEquals(slice.position(), 0);
600 assertEquals(slice.limit(), buf.remaining());
601 assertEquals(slice.capacity(), buf.remaining());
603 slice.reset();
611 if (!slice.isReadOnly()) {
612 loadTestData1(slice);
[all …]
DFloatBufferTest.java595 FloatBuffer slice = buf.slice(); in testSlice() local
596 assertEquals(buf.isReadOnly(), slice.isReadOnly()); in testSlice()
597 assertEquals(buf.isDirect(), slice.isDirect()); in testSlice()
598 assertEquals(buf.order(), slice.order()); in testSlice()
599 assertEquals(slice.position(), 0); in testSlice()
600 assertEquals(slice.limit(), buf.remaining()); in testSlice()
601 assertEquals(slice.capacity(), buf.remaining()); in testSlice()
603 slice.reset(); in testSlice()
610 if (!slice.isReadOnly()) { in testSlice()
611 loadTestData1(slice); in testSlice()
[all …]
DIntBufferTest.java571 IntBuffer slice = buf.slice(); in testSlice() local
572 assertEquals(buf.isReadOnly(), slice.isReadOnly()); in testSlice()
573 assertEquals(buf.isDirect(), slice.isDirect()); in testSlice()
574 assertEquals(buf.order(), slice.order()); in testSlice()
575 assertEquals(slice.position(), 0); in testSlice()
576 assertEquals(slice.limit(), buf.remaining()); in testSlice()
577 assertEquals(slice.capacity(), buf.remaining()); in testSlice()
579 slice.reset(); in testSlice()
586 if (!slice.isReadOnly()) { in testSlice()
587 loadTestData1(slice); in testSlice()
[all …]
DShortBufferTest.java558 ShortBuffer slice = buf.slice(); in testSlice() local
559 assertEquals(buf.isReadOnly(), slice.isReadOnly()); in testSlice()
560 assertEquals(buf.isDirect(), slice.isDirect()); in testSlice()
561 assertEquals(buf.order(), slice.order()); in testSlice()
562 assertEquals(slice.position(), 0); in testSlice()
563 assertEquals(slice.limit(), buf.remaining()); in testSlice()
564 assertEquals(slice.capacity(), buf.remaining()); in testSlice()
566 slice.reset(); in testSlice()
573 if (!slice.isReadOnly()) { in testSlice()
574 loadTestData1(slice); in testSlice()
[all …]
DCharBufferTest.java627 CharBuffer slice = buf.slice(); in testSlice() local
628 assertEquals(buf.isReadOnly(), slice.isReadOnly()); in testSlice()
629 assertEquals(buf.isDirect(), slice.isDirect()); in testSlice()
630 assertEquals(buf.order(), slice.order()); in testSlice()
631 assertEquals(slice.position(), 0); in testSlice()
632 assertEquals(slice.limit(), buf.remaining()); in testSlice()
633 assertEquals(slice.capacity(), buf.remaining()); in testSlice()
635 slice.reset(); in testSlice()
642 if (!slice.isReadOnly()) { in testSlice()
643 loadTestData1(slice); in testSlice()
[all …]
DSliceDirectByteBufferTest.java25 buf = buf.slice(); in setUp()
DSliceWrappedByteBufferTest.java25 buf = buf.slice(); in setUp()
DSliceHeapByteBufferTest.java25 buf = buf.slice(); in setUp()
DByteBufferTest.java813 ByteBuffer slice = buf.slice(); in testSlice() local
814 assertEquals(buf.isReadOnly(), slice.isReadOnly()); in testSlice()
815 assertEquals(buf.isDirect(), slice.isDirect()); in testSlice()
816 assertEquals(buf.order(), slice.order()); in testSlice()
817 assertEquals(slice.position(), 0); in testSlice()
818 assertEquals(slice.limit(), buf.remaining()); in testSlice()
819 assertEquals(slice.capacity(), buf.remaining()); in testSlice()
821 slice.reset(); in testSlice()
828 if (!slice.isReadOnly()) { in testSlice()
829 loadTestData1(slice); in testSlice()
[all …]
/libcore/luni/src/test/java/libcore/java/nio/charset/
DCharsetDecoderTest.java43 ByteBuffer inBuffer = ByteBuffer.wrap(arr, 0, arr.length).slice(); in test_ByteArray_decode_no_offset()
59 ByteBuffer inBuffer = ByteBuffer.wrap(arr, offset, arr.length - offset).slice(); in test_ByteArray_decode_with_offset()
117 CharBuffer out = cb.slice(); in testBufferWithNonZeroOffset()
/libcore/ojluni/src/test/java/util/stream/boottest/java/util/stream/
DNodeTest.java148 Node<Integer> slice = n.truncate(start, end, Integer[]::new); in testTruncate() local
149 Integer[] asArray = slice.asArray(Integer[]::new); in testTruncate()
DDoubleNodeTest.java173 Node.OfDouble slice = n.truncate(start, end, Double[]::new); in testTruncate() local
174 double[] asArray = slice.asPrimitiveArray(); in testTruncate()
DIntNodeTest.java171 Node.OfInt slice = n.truncate(start, end, Integer[]::new); in testTruncate() local
172 int[] asArray = slice.asPrimitiveArray(); in testTruncate()
DLongNodeTest.java172 Node.OfLong slice = n.truncate(start, end, Long[]::new); in testTruncate() local
173 long[] asArray = slice.asPrimitiveArray(); in testTruncate()
/libcore/ojluni/src/main/java/java/nio/
DStringCharBuffer.java44 public CharBuffer slice() { in slice() method in StringCharBuffer
DByteBufferAsFloatBuffer.java57 public FloatBuffer slice() { in slice() method in ByteBufferAsFloatBuffer
DByteBufferAsLongBuffer.java57 public LongBuffer slice() { in slice() method in ByteBufferAsLongBuffer
DByteBufferAsIntBuffer.java57 public IntBuffer slice() { in slice() method in ByteBufferAsIntBuffer
DByteBufferAsShortBuffer.java57 public ShortBuffer slice() { in slice() method in ByteBufferAsShortBuffer
DByteBufferAsDoubleBuffer.java58 public DoubleBuffer slice() { in slice() method in ByteBufferAsDoubleBuffer
DHeapShortBuffer.java75 public ShortBuffer slice() { in slice() method in HeapShortBuffer
DHeapDoubleBuffer.java76 public DoubleBuffer slice() { in slice() method in HeapDoubleBuffer

123