Home
last modified time | relevance | path

Searched refs:singleton (Results 1 – 25 of 39) sorted by relevance

12

/libcore/ojluni/src/test/java/util/Collections/
DEmptyCollectionSerialization.java68 Object singleton = o.get(); in serializableSingletons() local
69 … assertSame(o.get(), singleton, description + ": broken Supplier not returning singleton"); in serializableSingletons() local
70 Object copy = patheticDeepCopy(singleton); in serializableSingletons()
71 assertSame(copy, singleton, description + ": " + in serializableSingletons()
74singleton.getClass().getName() + "@" + Integer.toHexString(System.identityHashCode(singleton))); in serializableSingletons()
DSingletonIterator.java54 Iterator<String> it = Collections.singleton("TheOne").iterator(); in testForEachRemaining()
69 Iterator<String> it = Collections.singleton("TheOne").iterator(); in testThrowFromForEachRemaining()
DCheckedNull.java42 import static java.util.Collections.singleton;
93 check(c.addAll(singleton(o))); in add()
112 new F(){void f(){ c.addAll(singleton(1)); }}); in testCollection()
177 equal(m.keySet(), singleton("a")); in testMap()
179 singleton(new AbstractMap.SimpleImmutableEntry("a","b"))); in testMap()
DSer.java75 Set gumby = Collections.singleton("gumby"); in main()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
DSampleBundleClass.java27 private static SampleBundleClass singleton; field in SampleBundleClass
32 if (singleton != null) { in SampleBundleClass()
35 singleton = this; in SampleBundleClass()
DAbstractMapTest.java396 Set<Object> setOfNull = Collections.singleton(null);
/libcore/ojluni/src/main/java/sun/util/locale/
DInternalLocaleBuilder.java167 …public InternalLocaleBuilder setExtension(char singleton, String value) throws LocaleSyntaxExcepti… in setExtension() argument
169 boolean isBcpPrivateuse = LanguageTag.isPrivateusePrefixChar(singleton); in setExtension()
170 if (!isBcpPrivateuse && !LanguageTag.isExtensionSingletonChar(singleton)) { in setExtension()
171 throw new LocaleSyntaxException("Ill-formed extension key: " + singleton); in setExtension()
175 CaseInsensitiveChar key = new CaseInsensitiveChar(singleton); in setExtension()
244 String singleton = s; in setExtensions() local
245 StringBuilder sb = new StringBuilder(singleton); in setExtensions()
260 throw new LocaleSyntaxException("Incomplete extension '" + singleton + "'", in setExtensions()
DLocaleExtensions.java198 char singleton = entry.getKey(); in toID() local
200 if (LanguageTag.isPrivateusePrefixChar(singleton)) { in toID()
DLanguageTag.java347 String singleton = s; in parseExtensions() local
348 StringBuilder sb = new StringBuilder(singleton); in parseExtensions()
364 sts.errorMsg = "Incomplete extension '" + singleton + "'"; in parseExtensions()
/libcore/luni/src/test/java/libcore/android/compat/
DCompatibilityTest.java90 config = new ChangeConfig(Collections.emptySet(), Collections.singleton(5L)); in testGetDisabledChangesArray()
101 config = new ChangeConfig(Collections.singleton(5L), Collections.emptySet()); in testGetEnabledChangesArray()
/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/util/stream/
DExplodeOpTest.java94 …Collection<Integer> result = exerciseOps(data, s -> s.flatMap(i -> Collections.singleton(i).stream… in testIntOps()
109 …Collection<Long> result = exerciseOps(data, s -> s.flatMap(i -> Collections.singleton(i).stream().… in testLongOps()
124 …Collection<Double> result = exerciseOps(data, s -> s.flatMap(i -> Collections.singleton(i).stream(… in testDoubleOps()
/libcore/luni/src/test/java/libcore/java/security/cert/
DPKIXRevocationCheckerTest.java90 checker.setOptions(Collections.singleton(Option.SOFT_FAIL)); in test_getOptions()
91 assertEquals(Collections.singleton(Option.SOFT_FAIL), checker.getOptions()); in test_getOptions()
DOldPKIXParametersTest.java112 Set<TrustAnchor> taSet2 = Collections.singleton(new TrustAnchor( in testIsPolicyMappingInhibited()
141 Set<TrustAnchor> taSet2 = Collections.singleton(new TrustAnchor( in testIsRevocationEnabled()
DCertPathValidatorTest.java97 .singleton(new TrustAnchor((X509Certificate) rootCaEntry.getCertificate(), null))); in runOCSPStapledTest()
107 revChecker.setOptions(Collections.singleton(Option.ONLY_END_ENTITY)); in runOCSPStapledTest()
/libcore/ojluni/src/test/java/time/tck/java/time/zone/
DTCKZoneRulesProvider.java189 return new HashSet<String>(Collections.singleton("FooLocation")); in provideZoneIds()
212 return new HashSet<>(Collections.singleton("DynamicLocation")); in provideZoneIds()
/libcore/ojluni/src/test/java/security/cert/
DAKISerialNumberTest.java126 (Collections.singleton(anchor), sel); in main()
/libcore/ojluni/src/test/java/util/Collection/
DMOAT.java195 Set<Integer> singletonSet = singleton(1); in realMain()
469 () -> c.addAll(singleton(99))); in testImmutableCollection()
475 () -> c.removeAll(singleton(first)), in testImmutableCollection()
490 () -> c.addAll(0,singleton(86))); in testImmutableList()
823 final List<Integer> singleton = Collections.singletonList(e); in testQueueAddRemove() local
864 check(asList.subList(0, 1).equals(singleton)); in testQueueAddRemove()
874 case 7: check(deq.removeAll(singleton)); break; in testQueueAddRemove()
916 case 3: deq.addAll(singleton); break; in testQueueAddRemove()
917 case 4: asList.addAll(deq.size(), singleton); break; in testQueueAddRemove() local
931 check(asList.subList(size - 1, size).equals(singleton)); in testQueueAddRemove()
[all …]
/libcore/ojluni/src/main/java/sun/security/provider/certpath/
DPKIXCertPathValidator.java184 Collections.singleton(PolicyChecker.ANY_POLICY), in validate()
DSunCertPathBuilder.java330 Collections.singleton(PolicyChecker.ANY_POLICY); in depthFirstSearchForward()
/libcore/luni/src/main/java/javax/xml/xpath/
DXPathFactoryFinder.java329 return Collections.singleton(resource); in createServiceFileIterator()
/libcore/support/src/test/java/org/apache/harmony/security/tests/support/cert/
DTestUtils.java828 Collections.singleton(new TrustAnchor(rootCertificateSS, null)),
/libcore/luni/src/main/java/javax/xml/validation/
DSchemaFactoryFinder.java295 return Collections.singleton(classLoader.getResource(SERVICE_ID)); in createServiceFileIterator()
/libcore/luni/src/test/java/libcore/java/util/
DSetOfTest.java201 Set<T> examples = Collections.singleton(example); in assertUnmodifiable()
DCalendarTest.java335 Set<String> expected = Collections.singleton("gregory"); in testGetAvailableCalendarTypes()
/libcore/ojluni/src/test/java/util/EnumSet/
DInsertWrongType.java102 set.addAll(Collections.singleton(elt)); in addAllIllTypedElt()

12