/libcore/benchmarks/src/benchmarks/regression/ |
D | CharsetUtf8Benchmark.java | 55 new String(ASCII, StandardCharsets.UTF_8); in time_ascii() 59 new String(BMP2, StandardCharsets.UTF_8); in time_bmp2() 63 new String(BMP3, StandardCharsets.UTF_8); in time_bmp3() 67 new String(SUPPLEMENTARY, StandardCharsets.UTF_8); in time_supplementary()
|
D | StringToBytesBenchmark.java | 62 string.value.getBytes(StandardCharsets.UTF_8); in timeGetBytesUtf8()
|
/libcore/luni/src/test/java/libcore/java/net/ |
D | FtpURLConnectionTest.java | 53 import static java.nio.charset.StandardCharsets.UTF_8; 89 byte[] fileContents = "abcdef 1234567890".getBytes(UTF_8); in testInputUrl() 124 byte[] fileContents = "abcdef 1234567890".getBytes(UTF_8); in testOutputUrl() 126 byte[] newFileContents = "contents of brand new file".getBytes(UTF_8); in testOutputUrl() 140 byte[] fileContents = "abcdef 1234567890".getBytes(UTF_8); in testConnectOverProxy_noProxy() 176 byte[] fileContents = "abcdef 1234567890".getBytes(UTF_8); in testConnectOverProxy_explicit_http_uses_direct_connection() 196 byte[] fileContents = "abcdef 1234567890".getBytes(UTF_8); in testConnectOverProxy_implicit_http_fails() 224 byte[] fileContents = "abcdef 1234567890".getBytes(UTF_8); in testInputUrlWithSpaces() 239 byte[] fileContents = "abcdef 1234567890".getBytes(UTF_8); in testInputUrlWithSpacesViaProxySelector() 298 fail("Expected " + new String(expectedContents, UTF_8) + ", but got " in assertContents() [all …]
|
/libcore/luni/src/test/java/libcore/android/system/ |
D | UnixSocketAddressTest.java | 32 byte[] abstractNameBytes = path.getBytes(StandardCharsets.UTF_8); in testFilesystemSunPath() 47 byte[] abstractNameBytes = abstractName.getBytes(StandardCharsets.UTF_8); in testAbstractSunPath()
|
D | OsTest.java | 200 String s = new String(request, StandardCharsets.UTF_8); in checkUnixDomainSocket() 201 byte[] response = s.toUpperCase(Locale.ROOT).getBytes(StandardCharsets.UTF_8); in checkUnixDomainSocket() 219 byte[] request = string.getBytes(StandardCharsets.UTF_8); in checkUnixDomainSocket() 225 assertEquals(string.toUpperCase(Locale.ROOT), new String(response, StandardCharsets.UTF_8)); in checkUnixDomainSocket() 720 new String(requestBuf, 0, len, StandardCharsets.UTF_8); in createVmSocketEchoServer() 722 request.toUpperCase(Locale.ROOT).getBytes(StandardCharsets.UTF_8); in createVmSocketEchoServer() 753 final byte[] requestBuf = request.getBytes(StandardCharsets.UTF_8); 762 final String response = new String(responseBuf, StandardCharsets.UTF_8); 805 StandardCharsets.UTF_8); 1226 final byte[] VALUE_CAKE = "cake cake cake".getBytes(StandardCharsets.UTF_8); [all …]
|
/libcore/ojluni/src/main/java/java/util/zip/ |
D | ZipEntry.java | 128 if (name.getBytes(StandardCharsets.UTF_8).length > 0xffff) { in ZipEntry() 130 name.getBytes(StandardCharsets.UTF_8).length); in ZipEntry() 581 if (comment != null && comment.getBytes(StandardCharsets.UTF_8).length > 0xffff) { in setComment() 583 comment.getBytes(StandardCharsets.UTF_8).length); in setComment()
|
D | ZipCoder.java | 110 utf8 = new ZipCoder(StandardCharsets.UTF_8); in getBytesUTF8() 119 utf8 = new ZipCoder(StandardCharsets.UTF_8); in toStringUTF8() 135 this.isUTF8 = cs.name().equals(StandardCharsets.UTF_8.name()); in ZipCoder()
|
D | ZipInputStream.java | 81 this(in, StandardCharsets.UTF_8); in ZipInputStream()
|
/libcore/luni/src/main/java/android/system/ |
D | UnixSocketAddress.java | 76 byte[] nameBytes = name.getBytes(StandardCharsets.UTF_8); in createAbstract() 97 byte[] pathNameBytes = pathName.getBytes(StandardCharsets.UTF_8); in createFileSystem()
|
/libcore/luni/src/test/java/libcore/javax/crypto/ |
D | MacTest.java | 19 import static java.nio.charset.StandardCharsets.UTF_8; 121 byte[] salt = "saltsalt".getBytes(UTF_8); in test_PBEWITHHMACSHA_Variants()
|
D | SecretKeyFactoryTest.java | 19 import static java.nio.charset.StandardCharsets.UTF_8; 176 byte[] salt = "salt".getBytes(UTF_8); in test_PBKDF2_b8312059()
|
/libcore/ojluni/src/main/java/java/nio/charset/ |
D | StandardCharsets.java | 52 public static final Charset UTF_8 = Charset.forName("UTF-8"); field in StandardCharsets
|
/libcore/support/src/test/java/libcore/testing/io/ |
D | TestIoUtils.java | 35 return new String(Files.readAllBytes(Paths.get(absolutePath)), StandardCharsets.UTF_8); in readFileAsString()
|
/libcore/metrictests/memory/apps/src/libcore/heapdumper/ |
D | PssInstrumentation.java | 45 Charset cs = StandardCharsets.UTF_8; in takeMeasurement()
|
/libcore/luni/src/main/java/org/xml/sax/helpers/ |
D | XMLReaderFactory.java | 133 reader = new BufferedReader(new InputStreamReader(in, StandardCharsets.UTF_8)); in createXMLReader()
|
/libcore/luni/src/test/java/libcore/libcore/util/ |
D | HexEncodingTest.java | 57 { "avocados".getBytes(StandardCharsets.UTF_8), "61766F6361646F73" }, in testEncodeBytes()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/ |
D | PrintStreamTest.java | 103 assertFileContents(UNICODE_STRING.getBytes(StandardCharsets.UTF_8), testFile); in test_Constructor_Ljava_lang_String_Ljava_lang_String() 160 assertByteArraysEqual(UNICODE_STRING.getBytes(StandardCharsets.UTF_8), in test_ConstructorLjava_io_OutputStreamZLjava_lang_String() 686 byte[] bytes = "Line without a newline".getBytes(StandardCharsets.UTF_8); in test_autoFlush_flushesEverything() 704 byte[] bytes = "Line without a newline".getBytes(StandardCharsets.UTF_8); in test_noAutoFlush()
|
/libcore/ojluni/src/main/java/javax/net/ssl/ |
D | SNIHostName.java | 171 CharsetDecoder decoder = StandardCharsets.UTF_8.newDecoder() in SNIHostName()
|
/libcore/ojluni/src/main/java/java/nio/file/ |
D | Files.java | 2816 return newBufferedReader(path, StandardCharsets.UTF_8); 2896 return newBufferedWriter(path, StandardCharsets.UTF_8, options); 3242 return readAllLines(path, StandardCharsets.UTF_8); 3397 return write(path, lines, StandardCharsets.UTF_8, options); 3785 return lines(path, StandardCharsets.UTF_8);
|
/libcore/luni/src/test/java/libcore/java/util/zip/ |
D | GZIPInputStreamTest.java | 148 assertEquals("Hello World", new String(unzipped, StandardCharsets.UTF_8)); in testTrailingHeaderAndPartialMember()
|
/libcore/luni/src/test/java/libcore/dalvik/system/ |
D | BaseDexClassLoaderTest.java | 295 contents.add(new String(bytes, StandardCharsets.UTF_8)); in readResources() 309 return new String(contents, StandardCharsets.UTF_8); in readResource()
|
/libcore/luni/src/test/java/libcore/java/security/cert/ |
D | X509CRLTest.java | 19 import static java.nio.charset.StandardCharsets.UTF_8; 149 final BufferedReader buf = new BufferedReader(new InputStreamReader(ris, UTF_8)); in getCrlDates()
|
/libcore/luni/src/test/java/libcore/xml/ |
D | ExpatSaxParserTest.java | 119 Encoding.UTF_8, handler); in testSax() 727 UTF_8("UTF-8"), enumConstant
|
/libcore/luni/src/test/java/libcore/java/nio/charset/ |
D | CharsetEncoderTest.java | 222 CharsetEncoder encoder = StandardCharsets.UTF_8.newEncoder();
|
/libcore/luni/src/main/java/libcore/io/ |
D | IoUtils.java | 301 return new FileReader(absolutePath).readFully().toString(StandardCharsets.UTF_8); in readFileAsString()
|