/external/guava/guava-tests/test/com/google/common/io/ |
ResourcesTest.java | 58 assertEquals(I18N, Resources.toString(resource, Charsets.UTF_8)); 73 Resources.readLines(resource, Charsets.UTF_8)); 162 String text = Resources.toString(url, Charsets.UTF_8);
|
ByteSinkTester.java | 58 byte[] bytes = string.getBytes(Charsets.UTF_8);
|
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/ |
RequestTest.java | 36 RequestBody body = RequestBody.create(contentType, "abc".getBytes(Util.UTF_8)); 61 RequestBody body = RequestBody.create(contentType, "abc".getBytes(Util.UTF_8)); 70 RequestBody body = RequestBody.create(contentType, ".abcd".getBytes(Util.UTF_8), 1, 3);
|
/external/rappor/client/java/com/google/android/rappor/ |
Encoder.java | 306 this.encoderIdBytes = encoderId.getBytes(StandardCharsets.UTF_8); 404 return new String(encoderIdBytes, StandardCharsets.UTF_8); 446 byte[] stringInUtf8 = string.getBytes(StandardCharsets.UTF_8);
|
/external/apache-commons-compress/src/test/java/org/apache/commons/compress/archivers/zip/ |
UTF8ZipFilesTest.java | 46 testFileRoundtrip(CharsetNames.UTF_8, true, true); 52 testFileRoundtrip(CharsetNames.UTF_8, false, true); 70 testFileRoundtrip(CharsetNames.UTF_8, true, false); 76 testFileRoundtrip(CharsetNames.UTF_8, false, false); 383 CharsetNames.UTF_8));
|
/external/okhttp/okhttp-apache/src/test/java/com/squareup/okhttp/apache/ |
OkApacheClientTest.java | 28 import static com.squareup.okhttp.internal.Util.UTF_8; 62 String actual = EntityUtils.toString(response.getEntity(), UTF_8); 96 byte[] body = "Hello, world!".getBytes(UTF_8); 109 byte[] body = "Hello, world!".getBytes(UTF_8); 260 assertEquals(text, EntityUtils.toString(entity, UTF_8));
|
/external/apache-commons-compress/src/test/java/org/apache/commons/compress/archivers/tar/ |
TarArchiveOutputStreamTest.java | 141 CharsetNames.UTF_8)); 162 CharsetNames.UTF_8)); 163 assertEquals("6 a=b\n", new String(data, 512, 6, CharsetNames.UTF_8)); 179 CharsetNames.UTF_8)); 182 + "012\n", new String(data, 512, 99, CharsetNames.UTF_8)); 198 CharsetNames.UTF_8)); 201 + "0123\n", new String(data, 512, 101, CharsetNames.UTF_8)); 236 new String(data, 512, 160, CharsetNames.UTF_8)); 295 CharsetNames.UTF_8)); 338 new String(data, 512, 11, CharsetNames.UTF_8)); [all...] |
/external/protobuf/java/core/src/test/java/com/google/protobuf/ |
LiteralByteStringTest.java | 57 protected static final String UTF_8 = "UTF-8"; 401 ByteString unicode = ByteString.wrap(testString.getBytes(Internal.UTF_8)); 402 String roundTripString = unicode.toString(UTF_8); 408 ByteString unicode = ByteString.wrap(testString.getBytes(Internal.UTF_8)); 409 String roundTripString = unicode.toString(Internal.UTF_8); 415 ByteString.EMPTY.toString(Internal.UTF_8), 416 ByteString.wrap(new byte[]{}).toString(Internal.UTF_8));
|
NioByteStringTest.java | 33 import static com.google.protobuf.Internal.UTF_8; 425 String roundTripString = unicode.toString(UTF_8); 432 String roundTripString = unicode.toString(UTF_8); 438 EMPTY.toString(UTF_8), 439 new NioByteString(ByteBuffer.wrap(new byte[0])).toString(UTF_8)); 618 return new NioByteString(ByteBuffer.wrap(str.getBytes(UTF_8)));
|
/external/grpc-grpc-java/alts/src/test/java/io/grpc/alts/internal/ |
AltsProtocolNegotiatorTest.java | 20 import static java.nio.charset.StandardCharsets.UTF_8; 179 ByteBuf in = Unpooled.copiedBuffer(message, ix, 1, UTF_8); 217 assertEquals(message, unprotectedData.toString(UTF_8)); 234 assertEquals(message, channel.<ByteBuf>readInbound().toString(UTF_8)); 296 ByteBuf in = Unpooled.copiedBuffer(message, ix, 1, UTF_8); 324 ByteBuf in = Unpooled.copiedBuffer(message, UTF_8);
|
ChannelCrypterNettyTestBase.java | 22 import static java.nio.charset.StandardCharsets.UTF_8; 66 byte[] messageBytes = message.getBytes(UTF_8); 132 byte[] messageBytes = message.getBytes(UTF_8);
|
/external/robolectric-shadows/shadows/httpclient/src/test/java/org/robolectric/shadows/httpclient/ |
ShadowDefaultRequestDirectorTest.java | 4 import static java.nio.charset.StandardCharsets.UTF_8; 155 assertThat(CharStreams.toString(new InputStreamReader(getResponseStream, UTF_8))) 162 assertThat(CharStreams.toString(new InputStreamReader(postResponseStream, UTF_8))) 426 BufferedReader contentReader = new BufferedReader(new InputStreamReader(content, UTF_8)); 431 new BufferedReader(new InputStreamReader(new ByteArrayInputStream(cachedContent), UTF_8)); 452 return CharStreams.toString(new InputStreamReader(response.getEntity().getContent(), UTF_8));
|
/external/grpc-grpc-java/core/src/main/java/io/grpc/ |
Status.java | 20 import static com.google.common.base.Charsets.UTF_8; 574 byte[] valueBytes = value.getBytes(UTF_8); 645 return new String(buf.array(), 0, buf.position(), UTF_8);
|
/external/grpc-grpc-java/testing/src/main/java/io/grpc/internal/testing/ |
StatsTestUtils.java | 19 import static com.google.common.base.Charsets.UTF_8; 201 String serializedString = new String(bytes, UTF_8); 218 return (EXTRA_TAG_HEADER_VALUE_PREFIX + extraTagValue.asString()).getBytes(UTF_8);
|
/external/javapoet/src/main/java/com/squareup/javapoet/ |
JavaFile.java | 41 import static java.nio.charset.StandardCharsets.UTF_8; 97 try (Writer writer = new OutputStreamWriter(Files.newOutputStream(outputPath), UTF_8)) { 193 return new ByteArrayInputStream(getCharContent(true).getBytes(UTF_8));
|
/external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/ |
ShadowLogTest.java | 4 import static java.nio.charset.StandardCharsets.UTF_8; 175 assertThat(new String(bos.toByteArray(), UTF_8)) 179 assertTrue(new String(bos.toByteArray(), UTF_8).contains("RuntimeException"));
|
/external/turbine/java/com/google/turbine/main/ |
Main.java | 20 import static java.nio.charset.StandardCharsets.UTF_8; 177 units.add(Parser.parse(new SourceFile(source, MoreFiles.asCharSource(path, UTF_8).read()))); 183 String source = new String(ze.data(), UTF_8);
|
/cts/tests/framework/base/windowmanager/src/android/server/wm/intent/ |
IntentGenerationTests.java | 122 new String(Files.readAllBytes(testsFilePath), StandardCharsets.UTF_8));
|
/external/antlr/runtime/Ruby/lib/antlr3/streams/ |
interactive.rb | 41 line = line.to_s.encode( Encoding::UTF_8 )
|
/external/apache-commons-compress/src/main/java/org/apache/commons/compress/archivers/zip/ |
AbstractUnicodeExtraField.java | 57 unicodeName = text.getBytes(CharsetNames.UTF_8);
|
/external/caliper/caliper/src/main/java/com/google/caliper/config/ |
LoggingConfigLoader.java | 98 fileHandler.setEncoding(Charsets.UTF_8.name());
|
/external/caliper/caliper/src/main/java/com/google/caliper/runner/ |
TrialOutputFactoryService.java | 91 Charsets.UTF_8))));
|
/external/desugar/test/java/com/google/devtools/build/android/desugar/ |
BytecodeTypeInferenceTest.java | 47 String golden = Files.asCharSource(GOLDEN_PATH.toFile(), StandardCharsets.UTF_8).read().trim();
|
/external/guava/guava-tests/benchmark/com/google/common/base/ |
Utf8Benchmark.java | 115 byteArrays[i] = strings[i].getBytes(Charsets.UTF_8);
|
/external/protobuf/java/core/src/main/java/com/google/protobuf/ |
Internal.java | 59 static final Charset UTF_8 = Charset.forName("UTF-8"); 91 return new String(bytes.getBytes(ISO_8859_1), UTF_8); 187 return value.getBytes(UTF_8); 194 return new String(bytes, UTF_8);
|