/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/javax/net/ssl/ |
D | SSLEngineTest.java | 313 … ByteBuffer bbd = ByteBuffer.allocate(clientEngine.engine.getSession().getApplicationBufferSize()); in test_unwrap_01() 329 …ByteBuffer[] bbA = { ByteBuffer.allocate(100), ByteBuffer.allocate(10), ByteBuffer.allocate(100) }; in test_unwrap_02() 331 ByteBuffer bb = ByteBuffer.allocate(10); in test_unwrap_02() 365 ByteBuffer bbR = ByteBuffer.allocate(100).asReadOnlyBuffer(); in test_unwrap_03() 366 ByteBuffer[] bbA = { bbR, ByteBuffer.allocate(10), ByteBuffer.allocate(100) }; in test_unwrap_03() 368 ByteBuffer bb = ByteBuffer.allocate(10); in test_unwrap_03() 387 … ByteBuffer[] bbA = {ByteBuffer.allocate(100), ByteBuffer.allocate(10), ByteBuffer.allocate(100)}; in test_unwrap_04() 388 ByteBuffer[] bbAN = {ByteBuffer.allocate(100), null, ByteBuffer.allocate(100)}; in test_unwrap_04() 390 ByteBuffer bb = ByteBuffer.allocate(10); in test_unwrap_04() 425 …ByteBuffer[] bbA = { ByteBuffer.allocate(100), ByteBuffer.allocate(10), ByteBuffer.allocate(100) }; in test_unwrap_05() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/charset/ |
D | ASCIICharsetEncoderTest.java | 85 ByteBuffer out = ByteBuffer.allocate(10); in testMultiStepEncode() 91 out = ByteBuffer.allocate(10); in testMultiStepEncode() 127 ByteBuffer bb = ByteBuffer.allocate(0x10); in testEncodeMapping() 140 ByteBuffer out = ByteBuffer.allocate(0x10); in testInternalState() 162 ByteBuffer out = ByteBuffer.allocate(0x10); in testInternalState_Reset() 170 ByteBuffer out = ByteBuffer.allocate(0x10); in testInternalState_Reset() 177 ByteBuffer out = ByteBuffer.allocate(0x10); in testInternalState_Reset() 189 ByteBuffer out = ByteBuffer.allocate(0x10); in testInternalState_Encoding() 196 ByteBuffer out = ByteBuffer.allocate(0x10); in testInternalState_Encoding() 204 ByteBuffer out = ByteBuffer.allocate(0x10); in testInternalState_Encoding() [all …]
|
D | CharsetDecoderTest.java | 214 CharBuffer out = decoder.decode(ByteBuffer.allocate(0)); in implTestDecodeByteBuffer() 309 CharBuffer out = CharBuffer.allocate(100); in implTestDecodeByteBufferCharBuffer() 363 out = CharBuffer.allocate(4); in implTestDecodeByteBufferCharBuffer() 370 out = CharBuffer.allocate(100); in implTestDecodeByteBufferCharBuffer() 374 out = CharBuffer.allocate(100); in implTestDecodeByteBufferCharBuffer() 409 CharBuffer out = CharBuffer.allocate(50); in implTestDecodeCharBufferByteBufferUnmappedException() 463 CharBuffer out = CharBuffer.allocate(getString().length() * 3); in implTestDecodeCharBufferByteBufferMalformedException() 512 CharBuffer out = CharBuffer.allocate(50); in implTestDecodeCharBufferByteBufferException() 572 CharBuffer out = CharBuffer.allocate(10); in testFlush() 581 .flush(CharBuffer.allocate(10))); in testFlush() [all …]
|
D | CharsetEncoderTest.java | 275 encoder.encode(CharBuffer.wrap("aaa"), ByteBuffer.allocate(3), false); in testResetIllegalState() 277 encoder.encode(CharBuffer.wrap("aaa"), ByteBuffer.allocate(3), true); in testResetIllegalState() 283 ByteBuffer out = ByteBuffer.allocate(5); in testFlushIllegalState() 313 ByteBuffer out = ByteBuffer.allocate(5); in testFlushAfterConstructing() 350 ByteBuffer.allocate(30), true); in testEncodeFacadeIllegalState() 357 ByteBuffer.allocate(30), false); in testEncodeFacadeIllegalState() 364 ByteBuffer.allocate(30), true); in testEncodeFacadeIllegalState() 365 encoder.flush(ByteBuffer.allocate(10)); in testEncodeFacadeIllegalState() 373 ByteBuffer out = ByteBuffer.allocate(5); in testEncodeTrueIllegalState() 385 ByteBuffer.allocate(30), true); in testEncodeTrueIllegalState() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/channels/ |
D | SourceChannelTest.java | 68 sink.write(ByteBuffer.allocate(1)); in test_read_LByteBuffer_DataAvailable() 69 int count = source.read(ByteBuffer.allocate(10)); in test_read_LByteBuffer_DataAvailable() 90 ByteBuffer readBuf = ByteBuffer.allocate(BUFFER_SIZE); in test_read_LByteBuffer_SinkClosed() 108 ByteBuffer readBuf = ByteBuffer.allocate(BUFFER_SIZE); in test_read_LByteBuffer_SourceClosed() 172 ByteBuffer[] readBufArray = { ByteBuffer.allocate(BUFFER_SIZE), in test_read_$LByteBuffer() 173 ByteBuffer.allocate(BUFFER_SIZE) }; in test_read_$LByteBuffer() 236 ByteBuffer readBuf = ByteBuffer.allocate(BUFFER_SIZE); in test_read_$LByteBuffer_SinkClosed() 256 ByteBuffer readBuf = ByteBuffer.allocate(BUFFER_SIZE); in test_read_$LByteBuffer_SourceClosed() 315 ByteBuffer[] readBufArray = { ByteBuffer.allocate(BUFFER_SIZE), in test_read_$LByteBufferII() 316 ByteBuffer.allocate(BUFFER_SIZE) }; in test_read_$LByteBufferII() [all …]
|
D | FileChannelTest.java | 234 ByteBuffer readBuffer = ByteBuffer.allocate(CONTENT_LENGTH); in test_position_ReadOnly() 293 ByteBuffer readBuffer = ByteBuffer.allocate(CONTENT_LENGTH); in test_position_ReadWrite() 394 ByteBuffer readBuffer = ByteBuffer.allocate(CONTENT_LENGTH); in test_positionJ_ReadOnly() 464 ByteBuffer buf = ByteBuffer.allocate(8); in test_size() 466 ByteBuffer[] bufs = { ByteBuffer.allocate(8) }; in test_size() 1195 ByteBuffer readBuffer = ByteBuffer.allocate(CAPACITY); in test_readLByteBuffer_Closed() 1232 ByteBuffer readBuffer = ByteBuffer.allocate(CAPACITY); in test_readLByteBuffer_WriteOnly() 1250 ByteBuffer readBuffer = ByteBuffer.allocate(CAPACITY); in test_readLByteBuffer_EmptyFile() 1262 ByteBuffer readBuffer = ByteBuffer.allocate(LIMITED_CAPACITY); in test_readLByteBuffer_LimitedCapacity() 1275 ByteBuffer readBuffer = ByteBuffer.allocate(CONTENT_AS_BYTES_LENGTH); in test_readLByteBuffer() [all …]
|
D | SocketChannelTest.java | 1599 .allocate(CAPACITY_NORMAL); in testCFII_Data_ConnectWithServer() 1601 writeBufArr[0] = java.nio.ByteBuffer.allocate(CAPACITY_NORMAL); in testCFII_Data_ConnectWithServer() 1632 .allocate(CAPACITY_NORMAL); in testCFII_Data_ConnectWithServer_nonBlocking() 1634 writeBufArr[0] = java.nio.ByteBuffer.allocate(CAPACITY_NORMAL); in testCFII_Data_ConnectWithServer_nonBlocking() 1670 .allocate(CAPACITY_NORMAL); in testCFII_Data_FinishConnect_nonBlocking() 1672 writeBufArr[0] = java.nio.ByteBuffer.allocate(CAPACITY_NORMAL); in testCFII_Data_FinishConnect_nonBlocking() 1831 .allocate(CAPACITY_NORMAL); in testCFII_Data_FinishConnect_Blocking() 1833 writeBufArr[0] = java.nio.ByteBuffer.allocate(CAPACITY_NORMAL); in testCFII_Data_FinishConnect_Blocking() 1922 ByteBuffer readContent = ByteBuffer.allocate(CAPACITY_NORMAL + 1); in test_readLjava_nio_ByteBuffer_Blocking() 1966 ByteBuffer readContent = ByteBuffer.allocate(CAPACITY_NORMAL + 1); in test_readLjava_nio_ByteBuffer_Nonblocking() [all …]
|
D | SinkChannelTest.java | 86 ByteBuffer readBuf = ByteBuffer.allocate(BUFFER_SIZE); in test_write_LByteBuffer() 127 ByteBuffer readBuf = ByteBuffer.allocate(THREAD_NUM * BUFFER_SIZE); in test_write_LByteBuffer_mutliThread() 195 ByteBuffer readBuf = ByteBuffer.allocate(BUFFER_SIZE); in test_write_$LByteBuffer() 292 ByteBuffer readBuf = ByteBuffer.allocate(BUFFER_SIZE); in test_write_$LByteBufferII() 496 ByteBuffer[] buf = {ByteBuffer.allocate(10),null}; in test_socketChannel_read_write() 504 ByteBuffer target = ByteBuffer.allocate(10); in test_socketChannel_read_write()
|
/libcore/luni/src/test/java/libcore/java/nio/ |
D | BufferTest.java | 121 testByteSwappedBulkGet(ByteBuffer.allocate(10)); in testByteSwappedBulkGetHeap() 214 testByteSwappedBulkPut(ByteBuffer.allocate(10)); in testByteSwappedBulkPutHeap() 267 testByteBufferByteOrder(ByteBuffer.allocate(10), false); in testByteBufferByteOrderHeapRW() 279 testByteBufferByteOrder(ByteBuffer.allocate(10), true); in testByteBufferByteOrderHeapRO() 344 return ByteBuffer.allocate(10).order(order).asCharBuffer(); in allocateCharBuffer() 348 testCharBufferByteOrder(CharBuffer.allocate(10), ByteOrder.nativeOrder()); in testCharBufferByteOrderArray() 375 return ByteBuffer.allocate(10*8).order(order).asDoubleBuffer(); in allocateDoubleBuffer() 379 testDoubleBufferByteOrder(DoubleBuffer.allocate(10), ByteOrder.nativeOrder()); in testDoubleBufferByteOrderArray() 406 return ByteBuffer.allocate(10*8).order(order).asFloatBuffer(); in allocateFloatBuffer() 410 testFloatBufferByteOrder(FloatBuffer.allocate(10), ByteOrder.nativeOrder()); in testFloatBufferByteOrderArray() [all …]
|
D | CharBufferTest.java | 30 CharBuffer cb = CharBuffer.allocate(32).append(s); in testChars() 41 CharBuffer cb = CharBuffer.allocate(32).append(s); in testCodePoints() 51 cb = CharBuffer.allocate(32).append(surrogateCP); in testCodePoints()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/ |
D | HeapLongBufferTest.java | 23 buf = LongBuffer.allocate(BUFFER_LENGTH); in setUp() 36 LongBuffer.allocate(-1); in testAllocatedLongBuffer_IllegalArg()
|
D | HeapFloatBufferTest.java | 23 buf = FloatBuffer.allocate(BUFFER_LENGTH); in setUp() 36 FloatBuffer.allocate(-1); in testAllocatedFloatBuffer_IllegalArg()
|
D | HeapIntBufferTest.java | 23 buf = IntBuffer.allocate(BUFFER_LENGTH); in setUp() 36 IntBuffer.allocate(-1); in testAllocatedIntBuffer_IllegalArg()
|
D | HeapDoubleBufferTest.java | 23 buf = DoubleBuffer.allocate(BUFFER_LENGTH); in setUp() 36 DoubleBuffer.allocate(-1); in testAllocatedDoubleBuffer_IllegalArg()
|
D | HeapShortBufferTest.java | 23 buf = ShortBuffer.allocate(BUFFER_LENGTH); in setUp() 36 ShortBuffer.allocate(-1); in testAllocatedShortBuffer_IllegalArg()
|
D | HeapCharBufferTest.java | 25 buf = CharBuffer.allocate(BUFFER_LENGTH); in setUp() 38 CharBuffer.allocate(-1); in testAllocatedCharBuffer_IllegalArg()
|
D | HeapByteBufferTest.java | 26 buf = ByteBuffer.allocate(BUFFER_LENGTH); in setUp() 42 ByteBuffer.allocate(-1); in testAllocatedByteBuffer_IllegalArg()
|
D | ReadOnlyHeapLongBufferTest.java | 23 buf = LongBuffer.allocate(BUFFER_LENGTH); in setUp()
|
D | ReadOnlyHeapIntBufferTest.java | 23 buf = IntBuffer.allocate(BUFFER_LENGTH); in setUp()
|
/libcore/luni/src/test/java/libcore/java/nio/channels/ |
D | OldFileChannelTest.java | 260 ByteBuffer readBuffer = ByteBuffer.allocate(CAPACITY); in test_readLByteBufferJ_IllegalArgument() 545 readBuffers[0] = ByteBuffer.allocate(CAPACITY); in test_read$LByteBufferII_IndexOutOfBound() 546 readBuffers[1] = ByteBuffer.allocate(CAPACITY); in test_read$LByteBufferII_IndexOutOfBound() 610 readBuffers[0] = ByteBuffer.allocate(CAPACITY); in test_read$LByteBufferII_EmptyFile() 611 readBuffers[1] = ByteBuffer.allocate(CAPACITY); in test_read$LByteBufferII_EmptyFile() 620 readBuffers[0] = ByteBuffer.allocate(CAPACITY); in test_read$LByteBufferII_EmptyBuffers() 629 readBuffers[0] = ByteBuffer.allocate(CAPACITY); in test_read$LByteBufferII_EmptyBuffers() 653 ByteBuffer writeBuffer = ByteBuffer.allocate(CAPACITY); in test_writeLByteBuffer_Closed() 713 ByteBuffer writeBuffer = ByteBuffer.allocate(CAPACITY); in test_writeLByteBufferJ_IllegalArgument() 784 writeBuffers[0] = ByteBuffer.allocate(CAPACITY); in test_write$LByteBuffer_Closed() [all …]
|
/libcore/luni/src/test/java/libcore/java/nio/charset/ |
D | CharsetEncoderTest.java | 71 ByteBuffer bb = ByteBuffer.allocate(128); in testSurrogatePairAllAtOnce() 85 ByteBuffer bb = ByteBuffer.allocate(128); in testMalformedSurrogatePair() 122 ByteBuffer bb = ByteBuffer.allocate(128); in testCharsetEncoderSplitSurrogates() 146 ByteBuffer bb = ByteBuffer.allocate(128); in testFlushWithoutEndOfInput() 206 ByteBuffer bb = ByteBuffer.allocate(4); 207 CoderResult cr = e.encode(CharBuffer.allocate(0), bb, true); 223 ByteBuffer output = ByteBuffer.allocate(10);
|
D | CharsetDecoderTest.java | 44 CharBuffer outBuffer = CharBuffer.allocate(arr.length); in test_ByteArray_decode_no_offset() 60 CharBuffer outBuffer = CharBuffer.allocate(arr.length - offset); in test_ByteArray_decode_with_offset() 97 CharBuffer cb = CharBuffer.allocate(128); in testUtf8BytesSplitAcrossMultipleWrites() 115 CharBuffer cb = CharBuffer.allocate(128); in testBufferWithNonZeroOffset()
|
/libcore/luni/src/test/java/libcore/util/ |
D | NativeAllocationRegistryTest.java | 74 public long allocate() { in testNativeAllocation() 167 public long allocate() { in testNullArguments() 179 public long allocate() { in testNullArguments()
|
/libcore/support/src/test/java/libcore/javax/net/ssl/ |
D | TestSSLEnginePair.java | 89 ByteBuffer clientToServer = ByteBuffer.allocate(packetBufferSize); in connect() 90 ByteBuffer serverToClient = ByteBuffer.allocate(packetBufferSize); in connect() 93 ByteBuffer scratch = ByteBuffer.allocate(applicationBufferSize); in connect() 203 ByteBuffer emptyByteBuffer = ByteBuffer.allocate(0); in handshakeCompleted()
|
/libcore/luni/src/main/java/libcore/util/ |
D | NativeAllocationRegistry.java | 140 long allocate(); in allocate() method 172 long nativePtr = allocator.allocate(); in registerNativeAllocation()
|