/libcore/luni/src/test/java/libcore/java/nio/charset/ |
H A D | OldCharsetEncoderDecoderBufferTest.java | 41 CharBuffer out = CharBuffer.wrap(cBuf); 43 decoder.decode(ByteBuffer.wrap(new byte[]{(byte)'a', (byte)'b', (byte)'c', (byte)'d'}), 51 out = ByteBuffer.wrap(bBuf).asCharBuffer(); 53 decoder.decode(ByteBuffer.wrap(new byte[]{(byte)'x'}), out, true); 71 CharBuffer out = CharBuffer.wrap(new char[10]); 74 ByteBuffer inWithArray = ByteBuffer.wrap(inArray); 81 ByteBuffer inWithoutArray = ByteBuffer.wrap(new byte[] { (byte) 'x' }).asReadOnlyBuffer(); 99 ByteBuffer out = ByteBuffer.wrap(buffer); 102 encoder.encode(CharBuffer.wrap("ab"), out, false); 114 encoder.encode(CharBuffer.wrap(" [all...] |
H A D | CharsetDecoderTest.java | 35 ByteBuffer in = ByteBuffer.wrap(new byte[] { 109, 97, 109 }); 43 ByteBuffer inBuffer = ByteBuffer.wrap(arr, 0, arr.length).slice(); 59 ByteBuffer inBuffer = ByteBuffer.wrap(arr, offset, arr.length - offset).slice(); 75 CharBuffer outBuffer = decoder.decode(ByteBuffer.wrap(arr, offset, arr.length - offset)); 88 return encoder.encode(CharBuffer.wrap(s)).array(); 95 cr = decoder.decode(ByteBuffer.wrap(new byte[] { (byte) 0xe2 }), cb, false); 97 cr = decoder.decode(ByteBuffer.wrap(new byte[] { (byte) 0x98 }), cb, false); 99 cr = decoder.decode(ByteBuffer.wrap(new byte[] { (byte) 0x83 }), cb, false); 101 cr = decoder.decode(ByteBuffer.wrap(new byte[0]), cb, true);
|
H A D | CharsetEncoderTest.java | 36 String output = ascii.decode(e.encode(CharBuffer.wrap(input))).toString(); 70 CoderResult cr = e.encode(CharBuffer.wrap(new char[] { '\ud842', '\udf9f' }), bb, false); 84 CoderResult cr = e.encode(CharBuffer.wrap(new char[] { '\udf9f' }), bb, false); 116 CoderResult cr = e.encode(CharBuffer.wrap(new char[] { '\ud842' }), bb, false); 119 cr = e.encode(CharBuffer.wrap(new char[] { '\udf9f' }), bb, false); 137 cr = e.encode(CharBuffer.wrap(new char[] { }), bb, true); 165 CoderResult cr = e.encode(CharBuffer.wrap(new char[] { '\ud842' }), bb, false); 168 cr = e.encode(CharBuffer.wrap(new char[] { '\udf9f' }), bb, false); 177 cr = e.encode(CharBuffer.wrap(new char[] { }), bb, true); 189 CoderResult cr = e.encode(CharBuffer.wrap(ne [all...] |
H A D | OldCharset_SingleByteAbstractTest.java | 49 ByteBuffer inputBB = ByteBuffer.wrap(allBytes); 65 ByteBuffer inputBB = ByteBuffer.wrap(input); 90 // ByteBuffer inputBB = ByteBuffer.wrap(allBytes); 105 CharBuffer inputCB = CharBuffer.wrap(allChars);
|
/libcore/luni/src/main/java/javax/net/ssl/ |
H A D | SSLEngine.java | 78 * called by {@code wrap} or {@code unwrap} if the initial handshake has not 359 public abstract SSLEngineResult wrap(ByteBuffer[] srcs, int offset, int length, ByteBuffer dst) method in class:SSLEngine 434 public SSLEngineResult wrap(ByteBuffer[] srcs, ByteBuffer dst) throws SSLException { method in class:SSLEngine 438 return wrap(srcs, 0, srcs.length, dst); 461 public SSLEngineResult wrap(ByteBuffer src, ByteBuffer dst) throws SSLException { method in class:SSLEngine 462 return wrap(new ByteBuffer[] { src }, 0, 1, dst);
|
/libcore/support/src/test/java/libcore/javax/net/ssl/ |
H A D | TestTrustManager.java | 39 public static TrustManager[] wrap(TrustManager[] trustManagers) { method in class:TestTrustManager 42 result[i] = wrap(result[i]); 47 public static TrustManager wrap(TrustManager trustManager) { method in class:TestTrustManager
|
/libcore/luni/src/test/java/libcore/java/nio/ |
H A D | NoArrayTest.java | 26 assertNoArray(ByteBuffer.wrap(new byte[32]).asReadOnlyBuffer());
|
H A D | BufferTest.java | 214 // wrap always returns a big-endian buffer. 215 assertEquals(ByteOrder.BIG_ENDIAN, b.wrap(new byte[10]).order()); 250 assertEquals(ByteOrder.nativeOrder(), CharBuffer.wrap(new char[10]).order()); 251 assertEquals(ByteOrder.nativeOrder(), CharBuffer.wrap(new char[10]).asReadOnlyBuffer().order()); 281 assertEquals(ByteOrder.nativeOrder(), DoubleBuffer.wrap(new double[10]).order()); 282 assertEquals(ByteOrder.nativeOrder(), DoubleBuffer.wrap(new double[10]).asReadOnlyBuffer().order()); 312 assertEquals(ByteOrder.nativeOrder(), FloatBuffer.wrap(new float[10]).order()); 313 assertEquals(ByteOrder.nativeOrder(), FloatBuffer.wrap(new float[10]).asReadOnlyBuffer().order()); 343 assertEquals(ByteOrder.nativeOrder(), IntBuffer.wrap(new int[10]).order()); 344 assertEquals(ByteOrder.nativeOrder(), IntBuffer.wrap(ne [all...] |
/libcore/luni/src/main/java/org/apache/harmony/xnet/provider/jsse/ |
H A D | AlertProtocol.java | 132 // record protocol to be used to wrap the alerts 267 protected byte[] wrap() { method in class:AlertProtocol 268 byte[] res = recordProtocol.wrap(ContentType.ALERT, alert, 0, 2);
|
H A D | SSLSocketImpl.java | 516 output.write(alertProtocol.wrap()); 607 // warning alert occurred during wrap or unwrap 610 output.write(alertProtocol.wrap()); 646 output.write(recordProtocol.wrap(ContentType.APPLICATION_DATA, 650 output.write(recordProtocol.wrap( 658 recordProtocol.wrap(ContentType.APPLICATION_DATA, 674 * message from another peer. Each of this stages (wrap/unwrap) change 698 output.write(handshakeProtocol.wrap()); 737 // warning alert occurred during wrap or unwrap 740 output.write(alertProtocol.wrap()); [all...] |
/libcore/luni/src/test/java/tests/api/javax/net/ssl/ |
H A D | SSLEngineTest.java | 392 ByteBuffer bbs = ByteBuffer.wrap(new byte[] {1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,1,2,3,1,2,31,2,3,1,2,3,1,2,3,1,2,3}); 576 clientEngine.engine.wrap(new ByteBuffer[] { bbs }, 0, 1, bbd); 580 * javax.net.ssl.SSLEngine#wrap(ByteBuffer[] srcs, int offset, 594 sse.wrap(bbA, -1, 3, bb); 600 sse.wrap(bbA, 0, -3, bb); 606 sse.wrap(bbA, bbA.length + 1, bbA.length, bb); 612 sse.wrap(bbA, 0, bbA.length + 1, bb); 620 * javax.net.ssl.SSLEngine#wrap(ByteBuffer[] srcs, int offset, 633 sse.wrap(bbA, 0, bbA.length, bb); 641 * javax.net.ssl.SSLEngine#wrap(ByteBuffe [all...] |
/libcore/luni/src/main/java/java/nio/ |
H A D | CharBuffer.java | 30 * <li>{@link #wrap(char[]) Wrap} an existing char array to create a new 32 * <li>{@link #wrap(CharSequence) Wrap} an existing char sequence to create a 61 * {@code wrap(array, 0, array.length)}. 67 public static CharBuffer wrap(char[] array) { method in class:CharBuffer 68 return wrap(array, 0, array.length); 89 public static CharBuffer wrap(char[] array, int start, int charCount) { method in class:CharBuffer 101 * {@code wrap(chseq, 0, chseq.length())}. 107 public static CharBuffer wrap(CharSequence chseq) { method in class:CharBuffer 130 public static CharBuffer wrap(CharSequence cs, int start, int end) { method in class:CharBuffer
|
H A D | DoubleBuffer.java | 29 * <li>{@link #wrap(double[]) Wrap} an existing double array to create a new 59 * {@code wrap(array, 0, array.length)}. 65 public static DoubleBuffer wrap(double[] array) { method in class:DoubleBuffer 66 return wrap(array, 0, array.length); 87 public static DoubleBuffer wrap(double[] array, int start, int doubleCount) { method in class:DoubleBuffer
|
H A D | FloatBuffer.java | 29 * <li>{@link #wrap(float[]) Wrap} an existing float array to create a new 58 * {@code wrap(array, 0, array.length)}. 64 public static FloatBuffer wrap(float[] array) { method in class:FloatBuffer 65 return wrap(array, 0, array.length); 88 public static FloatBuffer wrap(float[] array, int start, int floatCount) { method in class:FloatBuffer
|
H A D | IntBuffer.java | 29 * <li>{@link #wrap(int[]) Wrap} an existing int array to create a new buffer;</li> 56 * {@code wrap(array, 0, array.length)}. 62 public static IntBuffer wrap(int[] array) { method in class:IntBuffer 63 return wrap(array, 0, array.length); 84 public static IntBuffer wrap(int[] array, int start, int intCount) { method in class:IntBuffer
|
H A D | LongBuffer.java | 29 * <li>{@link #wrap(long[]) Wrap} an existing long array to create a new 58 * {@code wrap(array, 0, array.length)}. 64 public static LongBuffer wrap(long[] array) { method in class:LongBuffer 65 return wrap(array, 0, array.length); 86 public static LongBuffer wrap(long[] array, int start, int longCount) { method in class:LongBuffer
|
H A D | ShortBuffer.java | 29 * <li>{@link #wrap(short[]) Wrap} an existing short array to create a new 58 * {@code wrap(array, 0, array.length)}. 64 public static ShortBuffer wrap(short[] array) { method in class:ShortBuffer 65 return wrap(array, 0, array.length); 86 public static ShortBuffer wrap(short[] array, int start, int shortCount) { method in class:ShortBuffer
|
/libcore/luni/src/main/java/java/io/ |
H A D | OutputStreamWriter.java | 265 CharBuffer chars = CharBuffer.wrap(buffer, offset, count); 285 CharBuffer chars = CharBuffer.wrap(new char[] { (char) oneChar }); 323 CharBuffer chars = CharBuffer.wrap(str, offset, count + offset);
|
/libcore/luni/src/test/java/libcore/java/nio/channels/ |
H A D | FileChannelTest.java | 68 fc.write(ByteBuffer.wrap("abcdABCD".getBytes("US-ASCII"))); 103 fc.write(ByteBuffer.wrap("hello".getBytes("US-ASCII"))); 108 fc.write(ByteBuffer.wrap(" world".getBytes("US-ASCII")));
|
H A D | ChannelsTest.java | 54 sinkChannel.write(ByteBuffer.wrap(content));
|
/libcore/luni/src/test/java/org/apache/harmony/crypto/tests/javax/crypto/func/ |
H A D | CipherWrapThread.java | 40 byte[] output = cip.wrap(key);
|
/libcore/luni/src/main/java/java/nio/channels/ |
H A D | Channels.java | 220 ByteBuffer buffer = ByteBuffer.wrap(target, offset, length); 263 ByteBuffer buffer = ByteBuffer.wrap(source, offset, length);
|
/libcore/luni/src/test/java/org/apache/harmony/security/tests/java/security/ |
H A D | MessageDigestSpiTest.java | 149 ByteBuffer buf = ByteBuffer.wrap(b, 0, b.length); 156 buf = ByteBuffer.wrap(b, 0, b.length);
|
/libcore/dalvik/src/main/java/org/apache/harmony/dalvik/ddmc/ |
H A D | ChunkHandler.java | 75 * Utility function to wrap a ByteBuffer around a Chunk. 80 in = ByteBuffer.wrap(request.data, request.offset, request.length);
|
/libcore/luni/src/test/java/libcore/java/util/ |
H A D | BitSetTest.java | 58 assertBitSet(BitSet.valueOf(LongBuffer.wrap(longs)), longs, s); 63 assertBitSet(BitSet.valueOf(LongBuffer.wrap(paddedLongs, 1, longs.length)), longs, s); 106 assertBitSet(BitSet.valueOf(ByteBuffer.wrap(bytes)), bytes, s); 111 assertBitSet(BitSet.valueOf(ByteBuffer.wrap(paddedBytes, 1, bytes.length)), bytes, s);
|