Home
last modified time | relevance | path

Searched refs:forName (Results 1 – 25 of 105) sorted by relevance

12345

/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/
DCharacter_UnicodeBlockTest.java507 … assertEquals(Character.UnicodeBlock.BASIC_LATIN, Character.UnicodeBlock.forName("BASIC_LATIN")); in test_forNameLjava_lang_String()
508 … assertEquals(Character.UnicodeBlock.BASIC_LATIN, Character.UnicodeBlock.forName("Basic Latin")); in test_forNameLjava_lang_String()
509 … assertEquals(Character.UnicodeBlock.BASIC_LATIN, Character.UnicodeBlock.forName("BasicLatin")); in test_forNameLjava_lang_String()
510 …assertEquals(Character.UnicodeBlock.LATIN_1_SUPPLEMENT, Character.UnicodeBlock.forName("LATIN_1_SU… in test_forNameLjava_lang_String()
511 …assertEquals(Character.UnicodeBlock.LATIN_1_SUPPLEMENT, Character.UnicodeBlock.forName("Latin-1 Su… in test_forNameLjava_lang_String()
512 …assertEquals(Character.UnicodeBlock.LATIN_1_SUPPLEMENT, Character.UnicodeBlock.forName("Latin-1Sup… in test_forNameLjava_lang_String()
513 …assertEquals(Character.UnicodeBlock.LATIN_EXTENDED_A, Character.UnicodeBlock.forName("LATIN_EXTEND… in test_forNameLjava_lang_String()
514 …assertEquals(Character.UnicodeBlock.LATIN_EXTENDED_A, Character.UnicodeBlock.forName("Latin Extend… in test_forNameLjava_lang_String()
515 …assertEquals(Character.UnicodeBlock.LATIN_EXTENDED_A, Character.UnicodeBlock.forName("LatinExtende… in test_forNameLjava_lang_String()
516 …assertEquals(Character.UnicodeBlock.LATIN_EXTENDED_B, Character.UnicodeBlock.forName("LATIN_EXTEND… in test_forNameLjava_lang_String()
[all …]
DClassTest.java91 Object.class, Class.forName("java.lang.Object")); in test_forNameLjava_lang_String()
93 Object[][].class, Class.forName("[[Ljava.lang.Object;")); in test_forNameLjava_lang_String()
96 int[].class, Class.forName("[I")); in test_forNameLjava_lang_String()
99 Class.forName("int"); in test_forNameLjava_lang_String()
105 Class.forName("byte"); in test_forNameLjava_lang_String()
110 Class.forName("char"); in test_forNameLjava_lang_String()
116 Class.forName("void"); in test_forNameLjava_lang_String()
122 Class.forName("short"); in test_forNameLjava_lang_String()
127 Class.forName("long"); in test_forNameLjava_lang_String()
133 Class.forName("boolean"); in test_forNameLjava_lang_String()
[all …]
/libcore/luni/src/main/java/java/nio/charset/
DStandardCharsets.java30 public static final Charset ISO_8859_1 = Charset.forName("ISO-8859-1");
35 public static final Charset US_ASCII = Charset.forName("US-ASCII");
40 public static final Charset UTF_8 = Charset.forName("UTF-8");
45 public static final Charset UTF_16 = Charset.forName("UTF-16");
50 public static final Charset UTF_16BE = Charset.forName("UTF-16BE");
55 public static final Charset UTF_16LE = Charset.forName("UTF-16LE");
DCharset.java280 public static Charset forName(String charsetName) { in forName() method in Charset
320 return Charset.forName(charsetName); in forNameUEE()
339 forName(charsetName); in isSupported()
560 return Charset.forName(encoding); in getDefaultCharset()
562 return Charset.forName("UTF-8"); in getDefaultCharset()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/charset/
DCharsetTest.java54 Charset cs = Charset.forName(charsetName); in test_allAvailableCharsets()
89 Charset cs = Charset.forName(name); in test_isRegistered()
97 Charset cs = Charset.forName(name); in test_isRegistered()
104 assertNotNull(Charset.forName("ISO-8859-1")); in test_guaranteedCharsetsAvailable()
105 assertNotNull(Charset.forName("US-ASCII")); in test_guaranteedCharsetsAvailable()
106 assertNotNull(Charset.forName("UTF-16")); in test_guaranteedCharsetsAvailable()
107 assertNotNull(Charset.forName("UTF-16BE")); in test_guaranteedCharsetsAvailable()
108 assertNotNull(Charset.forName("UTF-16LE")); in test_guaranteedCharsetsAvailable()
109 assertNotNull(Charset.forName("UTF-8")); in test_guaranteedCharsetsAvailable()
135 assertEquals("EUC-JP", Charset.forName("EUC-JP").name()); in test_have_canonical_EUC_JP()
[all …]
DCharsetEncoder2Test.java40 Charset cs = Charset.forName("UTF-8"); //$NON-NLS-1$ in test_ConstructorLjava_nio_charset_CharsetFF()
48 Charset cs = Charset.forName("ISO8859-1"); //$NON-NLS-1$ in test_ConstructorLjava_nio_charset_CharsetFF()
132 return Charset.forName("UTF-8").newDecoder(); in newDecoder()
158 Charset utf8 = Charset.forName("utf-8"); in test_EncodeLjava_nio_CharBufferLjava_nio_ByteBufferB()
203 Charset.forName("UTF-8").encode(CharBuffer.wrap(s)); in testUtf8Encoding()
DCharsetDecoder2Test.java44 Charset cs = Charset.forName("UTF-8"); //$NON-NLS-1$ in test_ConstructorLjava_nio_charset_CharsetFF()
91 CharsetDecoder decoder2 = Charset.forName("UTF-16").newDecoder(); in test_decode()
184 Charset cs = Charset.forName("UTF-8"); in testDecodeLjava_nio_ByteBuffer_ReplaceOverflow()
250 CharsetDecoder decoder = Charset.forName("UTF-8").newDecoder(); in testInvalidDecoding()
DAbstractCharsetTestCase.java53 this.testingCharset = Charset.forName(this.canonicalName); in setUp()
105 Charset c = Charset.forName(this.aliases[i]); in testAliases()
DISOCharsetDecoderTest.java29 cs = Charset.forName("iso-8859-1"); in setUp()
/libcore/luni/src/test/java/libcore/java/lang/
DCharacterTest.java144 assertEquals(Character.UnicodeBlock.BASIC_LATIN, Character.UnicodeBlock.forName("basic latin")); in test_UnicodeBlock_forName()
145 assertEquals(Character.UnicodeBlock.BASIC_LATIN, Character.UnicodeBlock.forName("BaSiC LaTiN")); in test_UnicodeBlock_forName()
146 assertEquals(Character.UnicodeBlock.BASIC_LATIN, Character.UnicodeBlock.forName("BasicLatin")); in test_UnicodeBlock_forName()
147 assertEquals(Character.UnicodeBlock.BASIC_LATIN, Character.UnicodeBlock.forName("BASIC_LATIN")); in test_UnicodeBlock_forName()
148 assertEquals(Character.UnicodeBlock.BASIC_LATIN, Character.UnicodeBlock.forName("basic_LATIN")); in test_UnicodeBlock_forName()
150 …assertEquals(Character.UnicodeBlock.HANGUL_JAMO_EXTENDED_B, Character.UnicodeBlock.forName("HANGUL… in test_UnicodeBlock_forName()
151 …assertEquals(Character.UnicodeBlock.HANGUL_JAMO_EXTENDED_B, Character.UnicodeBlock.forName("HANGUL… in test_UnicodeBlock_forName()
155 Character.UnicodeBlock.forName(null); in test_UnicodeBlock_forName()
160 Character.UnicodeBlock.forName("this unicode block does not exist"); in test_UnicodeBlock_forName()
166 assertEquals(Character.UnicodeBlock.GREEK, Character.UnicodeBlock.forName("Greek")); in test_UnicodeBlock_forName()
[all …]
DStringTest.java107 assertEquals("a\u0666b", new String(bytes, 1, bytes.length - 2, Charset.forName("UTF-8"))); in testString_BIICharset()
112 assertEquals("a\u0666b", new String(bytes, Charset.forName("UTF-8"))); in testString_BCharset()
129 … assertEquals("[97, 63, 98]", Arrays.toString("a\u0666b".getBytes(Charset.forName("US-ASCII")))); in test_getBytes_bad()
134 Charset cs = Charset.forName("UTF-8"); in test_getBytes_UTF_8()
172 … assertEquals("a\ufffdb", new String(new byte[] { 97, -2, 98 }, Charset.forName("US-ASCII"))); in test_new_String_bad()
222 String literal = (String) Class.forName("libcore.java.lang.StringTest$HasLiteral") in testInternBeforeLiteralIsLoaded()
347 CharsetDecoder decoder = Charset.forName("UTF-8").newDecoder(); in test_23831()
/libcore/luni/src/test/java/libcore/java/lang/reflect/
DOldAndroidClassTest.java32 Class helloClass = Class.forName(OldAndroidClassTest.class.getName()); in testNewInstance()
39 Class.forName("this.class.DoesNotExist"); in testForName()
47 Class.forName(packageName + ".ClassWithPrivateConstructor").newInstance(); in testNewInstancePrivateConstructor()
54 Class helloClass = Class.forName(OldAndroidClassTest.class.getName()); in testGetDeclaredMethod()
60 Class helloClass = Class.forName(OldAndroidClassTest.class.getName()); in testGetDeclaredMethodWithArgs()
70 Class helloClass = Class.forName(OldAndroidClassTest.class.getName()); in testGetDeclaredMethodPrivate()
76 Class helloClass = Class.forName(OldAndroidClassTest.class.getName()); in testGetSuperclass()
77 Class objectClass = Class.forName("java.lang.Object"); in testGetSuperclass()
82 Class helloClass = Class.forName(OldAndroidClassTest.class.getName()); in testIsAssignableFrom()
83 Class objectClass = Class.forName("java.lang.Object"); in testIsAssignableFrom()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/
DInputStreamReaderTest.java183 Charset cs = Charset.forName("utf-8"); in test_close()
184 assertEquals(cs, Charset.forName(reader.getEncoding())); in test_close()
241 assertEquals(Charset.forName(reader2.getEncoding()), Charset in test_ConstructorLjava_io_InputStreamLjava_lang_String()
242 .forName("utf-8")); in test_ConstructorLjava_io_InputStreamLjava_lang_String()
245 assertEquals(Charset.forName(reader2.getEncoding()), Charset in test_ConstructorLjava_io_InputStreamLjava_lang_String()
246 .forName("utf-8")); in test_ConstructorLjava_io_InputStreamLjava_lang_String()
256 Charset cs = Charset.forName("utf-8"); in test_ConstructorLjava_io_InputStreamLjava_nio_charset_Charset()
270 assertEquals(Charset.forName(reader2.getEncoding()), cs); in test_ConstructorLjava_io_InputStreamLjava_nio_charset_Charset()
280 CharsetDecoder decoder = Charset.forName("utf-8").newDecoder(); in test_ConstructorLjava_io_InputStreamLjava_nio_charset_CharsetDecoder()
294 assertEquals(Charset.forName(reader2.getEncoding()), decoder.charset()); in test_ConstructorLjava_io_InputStreamLjava_nio_charset_CharsetDecoder()
[all …]
DOutputStreamWriterTest.java342 assertEquals(Charset.forName("ascii"), Charset.forName(writer2 in testOutputStreamWriterOutputStreamString()
351 Charset cs = Charset.forName("ascii"); in testOutputStreamWriterOutputStreamCharset()
365 assertEquals(cs, Charset.forName(writer2.getEncoding())); in testOutputStreamWriterOutputStreamCharset()
374 Charset cs = Charset.forName("ascii"); in testOutputStreamWriterOutputStreamCharsetEncoder()
389 assertEquals(cs, Charset.forName(writer2.getEncoding())); in testOutputStreamWriterOutputStreamCharsetEncoder()
394 Charset cs = Charset.forName("utf-8"); in testGetEncoding()
395 assertEquals(cs, Charset.forName(writer.getEncoding())); in testGetEncoding()
/libcore/luni/src/test/java/libcore/java/nio/charset/
DCharsetDecoderTest.java31 CharsetDecoder d = Charset.forName("UTF-16").newDecoder(); in test_replaceWith()
41 CharsetDecoder decoder = Charset.forName("UTF-16").newDecoder(); in test_ByteArray_decode_no_offset()
55 CharsetDecoder decoder = Charset.forName("UTF-16").newDecoder(); in test_ByteArray_decode_with_offset()
71 CharsetDecoder decoder = Charset.forName("UTF-16").newDecoder(); in test_ByteArray_decode_with_offset_using_facade_method()
87 CharsetEncoder encoder = Charset.forName(charsetName).newEncoder(); in encode()
92 CharsetDecoder decoder = Charset.forName("UTF-8").newDecoder(); in testUtf8BytesSplitAcrossMultipleWrites()
DCharsetEncoderTest.java30 Charset ascii = Charset.forName("US-ASCII"); in test_replaceWith()
41 byte[] result = Charset.forName(charset).newEncoder().replacement(); in assertReplacementBytesForEncoder()
67 Charset cs = Charset.forName("UTF-32BE"); in testSurrogatePairAllAtOnce()
81 Charset cs = Charset.forName("UTF-32BE"); in testMalformedSurrogatePair()
116 Charset cs = Charset.forName("UTF-32BE"); in testCharsetEncoderSplitSurrogates()
142 Charset cs = Charset.forName("UTF-32BE"); in testFlushWithoutEndOfInput()
DOldCharsetEncoderDecoderBufferTest.java38 CharsetDecoder decoder = Charset.forName("UTF-8").newDecoder(); in testDecoderOutputBuffer()
70 CharsetDecoder decoder = Charset.forName("UTF-8").newDecoder(); in testDecoderInputBuffer()
96 CharsetEncoder encoder = Charset.forName("UTF-8").newEncoder(); in testEncoderOutputBuffer()
128 CharsetEncoder encoder = Charset.forName("UTF-8").newEncoder(); in testEncoderInputBuffer()
/libcore/luni/src/test/java/libcore/java/io/
DOldOutputStreamWriterTest.java75 Charset.forName(writer.getEncoding())); in test_ConstructorLjava_io_OutputStream()
118 Charset.forName("8859_1"), in test_ConstructorLjava_io_OutputStreamLjava_lang_String()
119 Charset.forName(osw.getEncoding())); in test_ConstructorLjava_io_OutputStreamLjava_lang_String()
126 Charset cs = Charset.forName("ascii"); in test_ConstructorLjava_io_OutputStreamLjava_nio_charset_Charset()
144 cs, Charset.forName(writer.getEncoding())); in test_ConstructorLjava_io_OutputStreamLjava_nio_charset_Charset()
152 Charset cs = Charset.forName("ascii"); in test_ConstructorLjava_io_OutputStreamLjava_nio_charset_CharsetEncoder()
171 cs, Charset.forName(writer.getEncoding())); in test_ConstructorLjava_io_OutputStreamLjava_nio_charset_CharsetEncoder()
330 Charset.forName("utf-8"), in test_getEncoding()
331 Charset.forName(writer.getEncoding())); in test_getEncoding()
/libcore/support/src/test/java/tests/support/
DSupport_ClassLoader.java38 factory = (Support_ClassLoader)Class.forName( in getInstance()
41 factory = (Support_ClassLoader)Class.forName( in getInstance()
/libcore/luni/src/test/java/tests/support/
DSupport_SQL.java51 InputStream in = Class.forName("tests.support.Support_SQL") in loadDriver()
64 Class.forName("SQLite.JDBCDriver").newInstance(); in loadDriver()
69 Class.forName(sqlDriver).newInstance(); in loadDriver()
/libcore/luni/src/main/java/javax/xml/transform/
DTransformerFactory.java78 return (TransformerFactory) Class.forName(className).newInstance(); in newInstance()
102 : Class.forName(factoryClassName); in newInstance()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/channels/
DChannelsTest.java362 Channels.newReader(rbChannel, Charset.forName(BAD_CODE_SET) in testnewReaderCharsetError()
375 Channels.newWriter(wbChannel, Charset.forName(BAD_CODE_SET) in testnewWriterCharsetError()
396 testReader = Channels.newReader(null, Charset.forName(CODE_SET).newDecoder(), -1); in testNewReaderReadableByteChannelString_InputNull()
410 testReader = Channels.newReader(rbChannel, Charset.forName(CODE_SET).newDecoder(), -1); in testNewReaderReadableByteChannelString_InputNull()
433 testReader = Channels.newReader(null, Charset.forName(CODE_SET).newDecoder(), 0); in testNewReaderReadableByteChannelString_internalBufferZero()
446 testReader = Channels.newReader(rbChannel, Charset.forName(CODE_SET).newDecoder(), -1); in testNewReaderReadableByteChannelString_internalBufferZero()
466 Reader testReader = Channels.newReader(rbChannel, Charset.forName( in testNewReaderReadableByteChannelString()
505 … Writer testWriter = Channels.newWriter(null, Charset.forName(CODE_SET).newEncoder(), -1); in testNewWriterWritableByteChannelString_internalBufZero()
524 Writer testWriter = Channels.newWriter(wbChannel, Charset.forName( in testNewWriterWritableByteChannelString_InputNull()
547 Writer testWriter_s = Channels.newWriter(wbChannel, Charset.forName( in testNewWriterWritableByteChannelString()
/libcore/luni/src/main/java/java/security/
DKeyStoreSpi.java475 .forName("java.security.KeyStore$TrustedCertificateEntry")); in engineEntryInstanceOf()
480 .forName("java.security.KeyStore$PrivateKeyEntry"))) { in engineEntryInstanceOf()
485 .forName("java.security.KeyStore$SecretKeyEntry"))) { in engineEntryInstanceOf()
517 Class<?> cl = Class.forName(clName); in getPasswordFromCallBack()
/libcore/benchmarks/src/benchmarks/regression/
DCharsetForNameBenchmark.java42 Charset.forName(charsetName); in timeCharsetForName()
/libcore/luni/src/main/java/java/net/
DURLDecoder.java60 return UriCodec.decode(s, true, Charset.forName(charsetName), true); in decode()

12345