Home
last modified time | relevance | path

Searched refs:ShortBuffer (Results 1 – 25 of 41) sorted by relevance

12

/libcore/ojluni/annotations/flagged_api/java/nio/
DShortBuffer.annotated.java34 public abstract class ShortBuffer extends java.nio.Buffer implements java.lang.Comparable<java.nio. class
36 ShortBuffer(int mark, int pos, int lim, int cap) { throw new RuntimeException("Stub!"); } in ShortBuffer() method in ShortBuffer
38 public static java.nio.ShortBuffer allocate(int capacity) { throw new RuntimeException("Stub!"); } in allocate()
40 public static java.nio.ShortBuffer wrap(short[] array, int offset, int length) { throw new RuntimeE… in wrap()
42 public static java.nio.ShortBuffer wrap(short[] array) { throw new RuntimeException("Stub!"); } in wrap()
44 public abstract java.nio.ShortBuffer slice(); in slice()
46 public abstract java.nio.ShortBuffer slice(int index, int length); in slice()
48 public abstract java.nio.ShortBuffer duplicate(); in duplicate()
50 public abstract java.nio.ShortBuffer asReadOnlyBuffer(); in asReadOnlyBuffer()
54 public abstract java.nio.ShortBuffer put(short s); in put()
[all …]
DByteBuffer.annotated.java147 public abstract java.nio.ShortBuffer asShortBuffer(); in asShortBuffer()
/libcore/ojluni/src/main/java/java/nio/
DShortBuffer.java272 public abstract class ShortBuffer class
274 implements Comparable<ShortBuffer>
294 ShortBuffer(int mark, int pos, int lim, int cap, // package-private in ShortBuffer() method in ShortBuffer
305 ShortBuffer(int mark, int pos, int lim, int cap) { // package-private in ShortBuffer() method in ShortBuffer
376 public static ShortBuffer allocate(int capacity) { in allocate()
421 public static ShortBuffer wrap(short[] array, in wrap()
454 public static ShortBuffer wrap(short[] array) { in wrap()
588 public abstract ShortBuffer slice(); in slice()
628 public abstract ShortBuffer slice(int index, int length); in slice()
651 public abstract ShortBuffer duplicate(); in duplicate()
[all …]
DHeapShortBuffer.java47 extends ShortBuffer
141 public ShortBuffer slice() { in slice()
157 public ShortBuffer slice(int index, int length) { in slice()
170 public ShortBuffer duplicate() { in duplicate()
182 public ShortBuffer asReadOnlyBuffer() { in asReadOnlyBuffer()
237 public ShortBuffer get(short[] dst, int offset, int length) { in get()
249 public ShortBuffer get(int index, short[] dst, int offset, int length) { in get()
270 public ShortBuffer put(short x) { in put()
282 public ShortBuffer put(int i, short x) { in put()
294 public ShortBuffer put(short[] src, int offset, int length) { in put()
[all …]
DByteBufferAsShortBuffer.java36 extends ShortBuffer
93 public ShortBuffer slice() { in slice()
104 public ShortBuffer slice(int index, int length) { in slice()
116 public ShortBuffer duplicate() { in duplicate()
127 public ShortBuffer asReadOnlyBuffer() { in asReadOnlyBuffer()
177 public ShortBuffer get(short[] dst, int off, int length) { in get()
187 public ShortBuffer get(int index, short[] dst, int off, int length) { in get()
209 public ShortBuffer put(short x) { in put()
225 public ShortBuffer put(int i, short x) { in put()
242 public ShortBuffer put(short[] src, int off, int length) { in put()
[all …]
DBufferMismatch.java84 static int mismatch(ShortBuffer a, int aOff, ShortBuffer b, int bOff, int length) { in mismatch()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/
DWrappedShortBufferTest.java18 import java.nio.ShortBuffer;
23 buf = ShortBuffer.wrap(new short[BUFFER_LENGTH]); in setUp()
41 ShortBuffer.wrap(array, -1, 0); in testWrappedShortBuffer_IllegalArg()
47 ShortBuffer.wrap(array, 21, 0); in testWrappedShortBuffer_IllegalArg()
53 ShortBuffer.wrap(array, 0, -1); in testWrappedShortBuffer_IllegalArg()
59 ShortBuffer.wrap(array, 0, 21); in testWrappedShortBuffer_IllegalArg()
65 ShortBuffer.wrap(array, Integer.MAX_VALUE, 1); in testWrappedShortBuffer_IllegalArg()
71 ShortBuffer.wrap(array, 1, Integer.MAX_VALUE); in testWrappedShortBuffer_IllegalArg()
77 ShortBuffer.wrap((short[])null, -1, 0); in testWrappedShortBuffer_IllegalArg()
82 ShortBuffer buf = ShortBuffer.wrap(array, 2, 16); in testWrappedShortBuffer_IllegalArg()
DShortBufferTest.java24 import java.nio.ShortBuffer;
36 protected ShortBuffer buf;
39 buf = ShortBuffer.allocate(BUFFER_LENGTH); in setUp()
89 ShortBuffer readonly = buf.asReadOnlyBuffer(); in testAsReadOnlyBuffer()
112 ShortBuffer ret = buf.compact(); in testCompact()
165 ShortBuffer other = ShortBuffer.allocate(buf.capacity()); in testCompareTo()
187 ShortBuffer duplicate = buf.duplicate();
216 ShortBuffer readonly = buf.asReadOnlyBuffer();
218 ShortBuffer duplicate = buf.duplicate();
260 ShortBuffer ret = buf.get(array); in testGetshortArray()
[all …]
DReadOnlyShortBufferTest.java19 import java.nio.ShortBuffer;
50 ShortBuffer duplicate = buf.duplicate(); in testHashCode()
126 ShortBuffer other = ShortBuffer.allocate(1); in testPutShortBuffer()
134 buf.put((ShortBuffer) null); in testPutShortBuffer()
DHeapShortBufferTest.java18 import java.nio.ShortBuffer;
23 buf = ShortBuffer.allocate(BUFFER_LENGTH); in setUp()
36 ShortBuffer.allocate(-1); in testAllocatedShortBuffer_IllegalArg()
DReadOnlyWrappedShortBufferTest.java18 import java.nio.ShortBuffer;
23 buf = ShortBuffer.wrap(new short[BUFFER_LENGTH]); in setUp()
DReadOnlyHeapShortBufferTest.java18 import java.nio.ShortBuffer;
23 buf = ShortBuffer.allocate(BUFFER_LENGTH); in setUp()
DDirectShortBufferTest.java22 import java.nio.ShortBuffer;
61 ShortBuffer shortBuffer = directByteBuffer.asShortBuffer(); in testJNIAccessByAddress()
DDirectByteBufferTest.java22 import java.nio.ShortBuffer;
76 ShortBuffer shortBuf = buf.asShortBuffer(); in testUnalignedReadsAndWrites()
/libcore/ojluni/src/test/java/nio/Buffer/
DBasicShort.java75 private static void relGet(ShortBuffer b) { in relGet()
82 private static void relGet(ShortBuffer b, int start) { in relGet()
89 private static void absGet(ShortBuffer b) { in absGet()
96 private static void bulkGet(ShortBuffer b) { in bulkGet()
105 private static void absBulkGet(ShortBuffer b) { in absBulkGet()
117 private static void relPut(ShortBuffer b) { in relPut()
125 private static void absPut(ShortBuffer b) { in absPut()
134 private static void bulkPutArray(ShortBuffer b) { in bulkPutArray()
144 private static void bulkPutBuffer(ShortBuffer b) { in bulkPutBuffer()
147 ShortBuffer c = ShortBuffer.allocate(n + 7); in bulkPutBuffer()
[all …]
DOrderShort.java37 private static void ckShortBuffer(ShortBuffer buf, ByteOrder expected) { in ckShortBuffer()
49 ShortBuffer buf = ShortBuffer.wrap(array); in ckShortBuffer()
53 buf = ShortBuffer.wrap(array, LENGTH/2, LENGTH/2); in ckShortBuffer()
57 buf = ShortBuffer.allocate(LENGTH); in ckShortBuffer()
DCopyDirectShortMemory.java32 private static void init(ShortBuffer b) { in init()
51 ShortBuffer b = bb.asShortBuffer(); in test()
DEqualsCompareTest.java42 import java.nio.ShortBuffer;
267 static class Shorts extends BufferType<ShortBuffer, Short> {
269 super(k, ShortBuffer.class, short.class); in Shorts()
273 ShortBuffer construct(int length, ByteOrder bo) { in construct()
285 return ShortBuffer.allocate(length); in construct()
DByteBufferViews.java43 import java.nio.ShortBuffer;
176 List<Map.Entry<String, Function<ByteBuffer, ShortBuffer>>> bfs = List.of( in shortViewProvider()
195 Function<ByteBuffer, ShortBuffer> fbi) { in testShortGet()
197 ShortBuffer vb = fbi.apply(bb); in testShortGet()
222 Function<ByteBuffer, ShortBuffer> fbi) { in testShortPut()
225 ShortBuffer vb = fbi.apply(bb); in testShortPut()
/libcore/luni/src/test/java/libcore/java/nio/
DOldDirectShortBufferTest.java20 import java.nio.ShortBuffer;
31 ShortBuffer shortBuffer = byteBuffer.asShortBuffer(); in testPutWhenOffsetIsNonZero()
DOldAndroidNIOTest.java26 import java.nio.ShortBuffer;
53 ShortBuffer sb = ShortBuffer.wrap(shortArray); in testNIO_short_array()
349 ShortBuffer sb = bb.asShortBuffer(); in byteBufferTest()
393 private void shortBufferTest(ShortBuffer sb) { in shortBufferTest()
DBufferTest.java39 import java.nio.ShortBuffer;
438 assertEquals(ByteOrder.nativeOrder(), ShortBuffer.wrap(new short[10]).order()); in testShortBufferByteOrderWrapped()
439 … assertEquals(ByteOrder.nativeOrder(), ShortBuffer.wrap(new short[10]).asReadOnlyBuffer().order()); in testShortBufferByteOrderWrapped()
442 private void testShortBufferByteOrder(ShortBuffer b, ByteOrder bo) throws Exception { in testShortBufferByteOrder()
452 private ShortBuffer allocateShortBuffer(ByteOrder order) { in allocateShortBuffer()
457 testShortBufferByteOrder(ShortBuffer.allocate(10), ByteOrder.nativeOrder()); in testShortBufferByteOrderArray()
919 assertEquals(Short.BYTES, 1 << ShortBuffer.allocate(0).getElementSizeShift()); in testElementSizeShifts()
1318 ShortBuffer s = b.asShortBuffer(); in testBuffersIndependentLimit()
1418 ShortBuffer sb_be = byteBuffer.asShortBuffer(); in test_ByteBufferAsXBuffer_ByteOrder_2()
1429 ShortBuffer sb_le = byteBuffer.asShortBuffer(); in test_ByteBufferAsXBuffer_ByteOrder_2()
/libcore/benchmarks/src/benchmarks/regression/
DByteBufferBulkBenchmark.java30 import java.nio.ShortBuffer;
DByteBufferBenchmark.java30 import java.nio.ShortBuffer;
241ShortBuffer src = ByteBufferBenchmark.newBuffer(byteOrder, aligned, bufferType).asShortBuffer(); in timeShortBuffer_getShortArray()
392ShortBuffer dst = ByteBufferBenchmark.newBuffer(byteOrder, aligned, bufferType).asShortBuffer(); in timeShortBuffer_putShortArray()
/libcore/ojluni/annotations/mmodule/java/nio/
DByteBuffer.annotated.java110 public abstract java.nio.ShortBuffer asShortBuffer(); in asShortBuffer()

12