Searched refs:decode (Results 1 - 25 of 86) sorted by path

1234

/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/
H A DOutputStreamTesterTest.java152 public byte[] decode(byte[] delegateBytes) throws Exception { method in class:OutputStreamTesterTest.FilterOutputStreamTester
168 public byte[] decode(byte[] delegateBytes) throws Exception { method in class:OutputStreamTesterTest.BufferedOutputStreamTester
179 public byte[] decode(byte[] delegateBytes) throws Exception { method in class:OutputStreamTesterTest.DataOutputStreamTester
190 public byte[] decode(byte[] delegateBytes) throws Exception { method in class:OutputStreamTesterTest.ObjectOutputStreamTester
202 public byte[] decode(byte[] delegateBytes) throws Exception { method in class:OutputStreamTesterTest.PrintStreamTester
H A DWriterTesterTest.java168 public char[] decode(char[] delegateChars) throws Exception { method in class:WriterTesterTest.BufferedWriterCharSinkTester
181 public char[] decode(char[] delegateChars) throws Exception { method in class:WriterTesterTest.FilterWriterCharSinkTester
194 public char[] decode(char[] delegateChars) throws Exception { method in class:WriterTesterTest.PrintWriterCharSinkTester
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/
H A DByteTest.java277 * java.lang.Byte#decode(String)
280 assertEquals(new Byte((byte) 0), Byte.decode("0"));
281 assertEquals(new Byte((byte) 1), Byte.decode("1"));
282 assertEquals(new Byte((byte) -1), Byte.decode("-1"));
283 assertEquals(new Byte((byte) 0xF), Byte.decode("0xF"));
284 assertEquals(new Byte((byte) 0xF), Byte.decode("#F"));
285 assertEquals(new Byte((byte) 0xF), Byte.decode("0XF"));
286 assertEquals(new Byte((byte) 07), Byte.decode("07"));
289 Byte.decode("9.2");
295 Byte.decode("");
[all...]
H A DIntegerTest.java67 * java.lang.Integer#decode(java.lang.String)
71 // java.lang.Integer.decode(java.lang.String)
73 132233, Integer.decode("132233").intValue());
75 07654321, Integer.decode("07654321").intValue());
77 Integer.decode("#1234567").intValue() == 0x1234567);
79 Integer.decode("0xdAd").intValue() == 0xdad);
80 assertEquals("Failed for -23", -23, Integer.decode("-23").intValue());
82 .decode("0").intValue());
83 assertEquals("Returned incorrect value for 0 hex", 0, Integer.decode("0x0")
86 Integer.decode("
[all...]
H A DLongTest.java67 * java.lang.Long#decode(java.lang.String)
71 // java.lang.Long.decode(java.lang.String)
72 assertEquals("Returned incorrect value for hex string", 255L, Long.decode(
74 assertEquals("Returned incorrect value for dec string", -89000L, Long.decode(
76 assertEquals("Returned incorrect value for 0 decimal", 0, Long.decode("0")
78 assertEquals("Returned incorrect value for 0 hex", 0, Long.decode("0x0")
82 Long.decode("-9223372036854775808").longValue() == 0x8000000000000000L);
85 Long.decode("-0x8000000000000000").longValue() == 0x8000000000000000L);
88 Long.decode("9223372036854775807").longValue() == 0x7fffffffffffffffL);
91 Long.decode("
[all...]
H A DShortTest.java62 * java.lang.Short#decode(java.lang.String)
66 // java.lang.Short.decode(java.lang.String)
67 assertTrue("Did not decode -1 correctly", Short.decode("-1")
69 assertTrue("Did not decode -100 correctly", Short.decode("-100")
71 assertTrue("Did not decode 23 correctly", Short.decode("23")
73 assertTrue("Did not decode 0x10 correctly", Short.decode("
[all...]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/net/
H A DURLDecoderTest.java38 * java.net.URLDecoder#decode(java.lang.String)
44 assertTrue("1. Incorrect encoding/decoding", URLDecoder.decode(
46 assertTrue("2. Incorrect encoding/decoding", URLDecoder.decode(
48 assertTrue("3. Incorrect encoding/decoding", URLDecoder.decode(
53 * java.net.URLDecoder#decode(java.lang.String, java.lang.String)
58 URLDecoder.decode("", "");
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/charset/
H A DAbstractCharsetTestCase.java160 CharBuffer chb = this.testingCharset.decode(ByteBuffer.wrap(input));
H A DCharsetDecoder2Test.java67 * @tests java.nio.charset.CharsetDecoder#decode(java.nio.ByteBuffer)
76 // decoder.decode(bb);
81 // CharBuffer charbuf = Charset.forName("UTF-16").decode(buf);
84 // charbuf = Charset.forName("UTF-16BE").decode(buf);
87 // charbuf = Charset.forName("UTF-16LE").decode(buf);
96 decoder2.decode(in);
104 * Test malfunction decode(ByteBuffer)
111 .onUnmappableCharacter(CodingErrorAction.REPLACE).decode(
121 cs2.decode(ByteBuffer.wrap(new byte[] { 0x00, 0x11 }));
122 fail("Assert 1: Charset.decode shoul
[all...]
H A DCharsetDecoderTest.java199 * Class under test for CharBuffer decode(ByteBuffer)
208 decoder.decode(null);
214 CharBuffer out = decoder.decode(ByteBuffer.allocate(0));
219 out = decoder.decode(in);
227 out = decoder.decode(in);
246 CharBuffer buffer = decoder.decode(in);
255 out = decoder.decode(in);
261 out = decoder.decode(in);
271 decoder.decode(in);
279 out = decoder.decode(i
[all...]
H A DCharsetEncoder2Test.java119 * Mock charset class with malfunction decode & encode.
187 CharBuffer chars = utf8.newDecoder().decode(bytes);
H A DCharsetTest.java251 CharBuffer out = cs.decode(in);
683 CharBuffer cb = c1.decode(ByteBuffer.wrap("abcdefg".getBytes("iso8859-1")));
685 cb = c1.decode(ByteBuffer.wrap("".getBytes("iso8859-1")));
691 CharBuffer cb = c1.decode(ByteBuffer.wrap("abcd\u5D14efg".getBytes("iso8859-1")));
699 c.decode(null);
708 c.decode(ByteBuffer.wrap("hehe".getBytes()));
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
H A DPropertyResourceBundleTest.java75 CharBuffer cbuffer = charset.decode(ByteBuffer.wrap(content
86 cbuffer = charset.decode(ByteBuffer.wrap(content.getBytes("UTF-8")));
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/javax/net/ssl/
H A DHandshakeCompletedEventTest.java538 byte[] bytes = Base64.getDecoder().decode(keys.getBytes());
H A DSSLServerSocketTest.java393 byte[] bytes = Base64.getDecoder().decode(keys.getBytes());
H A DSSLSessionTest.java630 byte[] bytes = Base64.getDecoder().decode(keys.getBytes());
H A DSSLSocketTest.java590 byte[] bytes = Base64.getDecoder().decode(keys.getBytes());
/libcore/libart/src/main/java/java/lang/
H A DStringFactory.java238 CharBuffer cb = charset.decode(ByteBuffer.wrap(data, offset, byteCount));
/libcore/luni/src/main/java/java/nio/charset/
H A DCharsetDecoderICU.java117 int error = NativeConverter.decode(converterHandle, input, inEnd, output, outEnd, data, true);
143 int error = NativeConverter.decode(converterHandle, input, inEnd, output, outEnd, data, false);
H A DModifiedUtf8.java118 public static String decode(byte[] in, char[] out, int offset, int length) method in class:ModifiedUtf8
/libcore/luni/src/main/java/libcore/icu/
H A DNativeConverter.java23 public static native int decode(long converterHandle, byte[] input, int inEnd, method in class:NativeConverter
/libcore/luni/src/main/java/libcore/net/
H A DUriCodec.java271 public static String decode( method in class:UriCodec
358 builder.append(decoder.decode(byteBuffer));
373 * Equivalent to {@code decode(s, false, UTF_8, true)}
375 public static String decode(String s) { method in class:UriCodec
376 return decode(
/libcore/luni/src/main/java/libcore/util/
H A DHexEncoding.java64 public static byte[] decode(String encoded) throws IllegalArgumentException { method in class:HexEncoding
65 return decode(encoded.toCharArray());
75 public static byte[] decode(String encoded, boolean allowSingleChar) throws IllegalArgumentException { method in class:HexEncoding
76 return decode(encoded.toCharArray(), allowSingleChar);
85 public static byte[] decode(char[] encoded) throws IllegalArgumentException { method in class:HexEncoding
86 return decode(encoded, false);
96 public static byte[] decode(char[] encoded, boolean allowSingleChar) throws IllegalArgumentException { method in class:HexEncoding
/libcore/luni/src/main/native/
H A Dlibcore_icu_NativeConverter.cpp682 NATIVE_METHOD(NativeConverter, decode, "(J[BI[CI[IZ)I"),
/libcore/luni/src/test/java/com/android/org/bouncycastle/jce/provider/
H A DCertBlacklistTest.java220 byte[] derCert = Base64.decode(cert.getBytes());
227 byte[] derCert = Base64.decode(cert.getBytes());

Completed in 560 milliseconds

1234