Home
last modified time | relevance | path

Searched refs:id (Results 1 – 25 of 79) sorted by relevance

1234

/libcore/ojluni/src/test/java/util/Random/
DRandomTestChiSquared.java127 static boolean chiSquaredTest(String id, int N, IntSupplier theSupplier) { in chiSquaredTest() argument
142 …aredSuccess) fail("chi-squared test failure for %s: x=%g (should be in [%g,%g])\n", id, x, lo, hi); in chiSquaredTest()
146 static boolean testRngChiSquared(String id, int N, IntSupplier theSupplier) { in testRngChiSquared() argument
147 if (chiSquaredTest(id, N, theSupplier)) return true; in testRngChiSquared()
149 return chiSquaredTest(id, N, theSupplier) && chiSquaredTest(id, N, theSupplier); in testRngChiSquared()
153 String id = rng.getClass().getName() + " " + kind; in tryIt() local
155 boolean success = f.apply(id).getAsBoolean(); in tryIt()
157 fail("*** Failure of %s\n", id); in tryIt()
177 …tryIt(rng, "nextInt(" + N + ")", (String id) -> () -> testRngChiSquared(id, N, () -> rng.nextInt(N… in testOneRng()
178 …tryIt(rng, "nextInt(43, " + (N+43) + ")", (String id) -> () -> testRngChiSquared(id, N, () -> rng.… in testOneRng()
[all …]
DRandomTestBsi1999.java136 static int monobitTest(String id, byte[] s) { in monobitTest() argument
143 …ilure != 0) fail("monobit test failure for %s: count=%d (should be in [9654,10346])\n", id, count); in monobitTest()
158 static int pokerTest(String id, byte[] s) { in pokerTest() argument
176 …if (pokerFailure != 0) fail("poker test failure for %s: x=%g (should be in [1.03,57.4])\n", id, x); in pokerTest()
207 static int runTestAndLongRunTest(String id, byte[] s) { in runTestAndLongRunTest() argument
221 if (runFailure != 0) fail("run test failure for %s\n", id); in runTestAndLongRunTest()
223 if (longRunFailure != 0) fail("long run test failure for %s\n", id); in runTestAndLongRunTest()
245 static int autocorrelationTest(String id, byte[] s) { in autocorrelationTest() argument
260 …l("autocorrelation failure for %s: count=%d (should be in [2267,2733]), tau=%d\n", id, count, tau); in autocorrelationTest()
273 static int entireBsi1999Test(String id, byte[] s) { in entireBsi1999Test() argument
[all …]
/libcore/ojluni/src/main/java/sun/security/x509/
DUniqueIdentity.java41 private BitArray id; field in UniqueIdentity
48 public UniqueIdentity(BitArray id) { in UniqueIdentity() argument
49 this.id = id; in UniqueIdentity()
57 public UniqueIdentity(byte[] id) { in UniqueIdentity() argument
58 this.id = new BitArray(id.length*8, id); in UniqueIdentity()
69 id = derVal.getUnalignedBitString(true); in UniqueIdentity()
80 id = derVal.getUnalignedBitString(true); in UniqueIdentity()
87 return ("UniqueIdentity:" + id.toString() + "\n"); in toString()
98 byte[] bytes = id.toByteArray(); in encode()
99 int excessBits = bytes.length*8 - id.length(); in encode()
[all …]
DCertificatePolicyId.java39 private ObjectIdentifier id; field in CertificatePolicyId
46 public CertificatePolicyId(ObjectIdentifier id) { in CertificatePolicyId() argument
47 this.id = id; in CertificatePolicyId()
56 this.id = val.getOID(); in CertificatePolicyId()
63 return (id); in getIdentifier()
71 + id.toString() in toString()
84 out.putOID(id); in encode()
96 return id.equals((Object) in equals()
108 return id.hashCode(); in hashCode()
DSubjectKeyIdentifierExtension.java70 private KeyIdentifier id = null; field in SubjectKeyIdentifierExtension
74 if (id == null) { in encodeThis()
79 id.encode(os); in encodeThis()
90 id = new KeyIdentifier(octetString); in SubjectKeyIdentifierExtension()
111 this.id = new KeyIdentifier(val); in SubjectKeyIdentifierExtension()
119 + String.valueOf(id) + "]\n"; in toString()
148 id = (KeyIdentifier)obj; in set()
161 return (id); in get()
173 id = null; in delete()
DAuthorityKeyIdentifierExtension.java78 private KeyIdentifier id = null; field in AuthorityKeyIdentifierExtension
84 if (id == null && names == null && serialNum == null) { in encodeThis()
90 if (id != null) { in encodeThis()
92 id.encode(tmp1); in encodeThis()
129 this.id = kid; in AuthorityKeyIdentifierExtension()
168 if (id != null) in AuthorityKeyIdentifierExtension()
172 id = new KeyIdentifier(opt); in AuthorityKeyIdentifierExtension()
200 if (id != null) { in toString()
201 s += id.toString(); // id already has a newline in toString()
238 id = (KeyIdentifier)obj; in set()
[all …]
DX509CertImpl.java662 String id = attr.getPrefix(); in get() local
663 if (!(id.equalsIgnoreCase(NAME))) { in get()
666 "], received " + "[" + id + "]"); in get()
669 id = attr.getPrefix(); in get()
671 if (id.equalsIgnoreCase(INFO)) { in get()
686 } else if (id.equalsIgnoreCase(ALG_ID)) { in get()
688 } else if (id.equalsIgnoreCase(SIGNATURE)) { in get()
693 } else if (id.equalsIgnoreCase(SIGNED_CERT)) { in get()
700 + "recognized or get() not allowed for the same: " + id); in get()
720 String id = attr.getPrefix(); in set() local
[all …]
/libcore/luni/src/test/java/org/apache/harmony/security/tests/java/security/
DIdentityScope2Test.java99 public void addIdentity(Identity id) throws KeyManagementException { in addIdentity() argument
100 if (identities.containsKey(id)) in addIdentity()
103 if (getIdentity(id.getPublicKey()) != null) in addIdentity()
106 identities.put(id, id); in addIdentity()
109 public void removeIdentity(Identity id) throws KeyManagementException { in removeIdentity() argument
110 if (!identities.containsKey(id)) in removeIdentity()
113 identities.remove(id); in removeIdentity()
186 Identity id = new IdentitySubclass("id1"); in test_addIdentityLjava_security_Identity() local
187 id.setPublicKey(getPubKey()); in test_addIdentityLjava_security_Identity()
188 sub.addIdentity(id); in test_addIdentityLjava_security_Identity()
[all …]
/libcore/ojluni/src/main/java/sun/nio/fs/
DUnixUserPrincipals.java44 private final int id; // uid or gid field in UnixUserPrincipals.User
48 private User(int id, boolean isGroup, String name) { in User() argument
49 this.id = id; in User()
54 User(int id, String name) { in User() argument
55 this(id, false, name); in User()
61 return id; in uid()
66 return id; in gid()
71 return id == -1; in isSpecial()
91 if ((this.id != other.id) || in equals()
96 if (this.id == -1 && other.id == -1) in equals()
[all …]
/libcore/luni/src/test/java/tests/support/
DDatabaseCreator.java341 for (int id = 0; id < numberOfRecords; id++) { in fillTestTable1()
342 String value = DatabaseCreator.defaultString + id; in fillTestTable1()
344 + " (id, field1, field2, field3) VALUES(" + id + ", '" in fillTestTable1()
345 + value + "', " + id + ", " + id + ")"; in fillTestTable1()
353 for (int id = startID; id <= endID; id++) { in fillTestTable2()
354 double value = id + DatabaseCreator.defaultDouble; in fillTestTable2()
358 + " VALUES (" + id + ", '" + DatabaseCreator.defaultString in fillTestTable2()
359 + id + "'," + " '" + DatabaseCreator.defaultCharacter + id in fillTestTable2()
371 for (int id = 0; id < numberOfRecords; id++) { in fillTestTable2()
372 double value = id + DatabaseCreator.defaultDouble; in fillTestTable2()
[all …]
/libcore/ojluni/src/main/java/sun/util/locale/provider/
DCalendarDataUtility.java141 public static String retrieveFieldValueName(String id, int field, int value, int style, in retrieveFieldValueName() argument
145 switch (normalizeCalendarType(id)) { in retrieveFieldValueName()
165 String[] names = getNames(id, field, style, locale); in retrieveFieldValueName()
188 public static String retrieveJavaTimeFieldValueName(String id, int field, int value, int style, in retrieveJavaTimeFieldValueName() argument
191 return retrieveFieldValueName(id, field, value, style, locale); in retrieveJavaTimeFieldValueName()
204 public static Map<String, Integer> retrieveFieldValueNames(String id, int field, int style, in retrieveFieldValueNames() argument
208 names = retrieveFieldValueNamesImpl(id, field, SHORT_FORMAT, locale); in retrieveFieldValueNames()
210 names.putAll(retrieveFieldValueNamesImpl(id, field, st, locale)); in retrieveFieldValueNames()
214 names = retrieveFieldValueNamesImpl(id, field, style, locale); in retrieveFieldValueNames()
235 public static Map<String, Integer> retrieveJavaTimeFieldValueNames(String id, int field, in retrieveJavaTimeFieldValueNames() argument
[all …]
/libcore/ojluni/src/test/java/time/tck/java/time/
DTCKZoneId.java230 public void factory_of_String_offsetBasedValid_noPrefix(String input, String id) { in factory_of_String_offsetBasedValid_noPrefix() argument
232 assertEquals(test.getId(), id); in factory_of_String_offsetBasedValid_noPrefix() local
233 assertEquals(test, ZoneOffset.of(id)); in factory_of_String_offsetBasedValid_noPrefix()
234 assertEquals(test.normalized(), ZoneOffset.of(id)); in factory_of_String_offsetBasedValid_noPrefix()
235 assertEquals(test.getDisplayName(TextStyle.FULL, Locale.UK), id); in factory_of_String_offsetBasedValid_noPrefix() local
237 assertEquals(test.getRules().getOffset(Instant.EPOCH), ZoneOffset.of(id)); in factory_of_String_offsetBasedValid_noPrefix()
278 …public void factory_of_String_offsetBasedValid_prefixUTC(String input, String id, String offsetId)… in factory_of_String_offsetBasedValid_prefixUTC() argument
280 assertEquals(test.getId(), "UTC" + id); in factory_of_String_offsetBasedValid_prefixUTC() local
283 assertEquals(test.getDisplayName(TextStyle.FULL, Locale.UK), displayName("UTC" + id)); in factory_of_String_offsetBasedValid_prefixUTC()
289 …public void factory_of_String_offsetBasedValid_prefixGMT(String input, String id, String offsetId)… in factory_of_String_offsetBasedValid_prefixGMT() argument
[all …]
/libcore/luni/src/test/java/tests/java/sql/
DMultiThreadAccessTest.java202 int id = 1; in test_MultipleUpdatesInOneTables() local
206 + " WHERE id=" + id; in test_MultipleUpdatesInOneTables()
210 assertTrue("There is no records with id = " + id, result.next()); in test_MultipleUpdatesInOneTables()
217 threadPool.runTask(createTask7(id, field)); in test_MultipleUpdatesInOneTables()
222 double expectedVal = id + numThreads; in test_MultipleUpdatesInOneTables()
224 assertTrue("There is no records with id = " + id, result.next()); in test_MultipleUpdatesInOneTables()
280 int id = result.getInt("finteger");
282 DatabaseCreator.defaultString + id, result
285 DatabaseCreator.defaultCharacter + id,
288 DatabaseCreator.defaultDouble + id, result
[all …]
DSelectFunctionalityTest.java136 int id = result.getInt("finteger"); in test_SelectSimple() local
138 DatabaseCreator.defaultString + id, result in test_SelectSimple()
141 DatabaseCreator.defaultCharacter + id, result in test_SelectSimple()
152 .valueOf(id + 0.1).floatValue(), result.getFloat("ffloat")); in test_SelectSimple()
154 .valueOf(id + 0.1).doubleValue(), result.getDouble("freal")); in test_SelectSimple()
156 .valueOf(id + 0.1).doubleValue(), result in test_SelectSimple()
199 int id = result.getInt("finteger"); in test_SelectPrepared() local
201 DatabaseCreator.defaultString + id, result in test_SelectPrepared()
204 DatabaseCreator.defaultCharacter + id, result in test_SelectPrepared()
211 assertEquals("expected value doesn't equal actual", id, result in test_SelectPrepared()
[all …]
/libcore/ojluni/src/main/java/java/time/
DZoneRegion.java100 private final String id; field in ZoneRegion
163 ZoneRegion(String id, ZoneRules rules) { in ZoneRegion() argument
164 this.id = id; in ZoneRegion()
171 return id; in getId()
178 return (rules != null ? rules : ZoneRulesProvider.getRules(id, false)); in getRules()
216 out.writeUTF(id); in writeExternal()
220 String id = in.readUTF(); in readExternal() local
221 return ZoneId.of(id, false); in readExternal()
/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/util/stream/
DSequentialOpTest.java54 Function<Integer, Integer> id = LambdaTestHelpers.identity(); in testLazy() local
60 …(UnaryOperator<Stream<Integer>>) s -> s.map(id).peek(e -> { counter.incrementAndGet(); }).sequenti… in testLazy()
61 …(UnaryOperator<Stream<Integer>>) s -> s.map(id).peek(e -> { counter.incrementAndGet(); }).parallel… in testLazy()
62 (UnaryOperator<Stream<Integer>>) s -> s.sequential().map(id).peek(e -> { in testLazy()
64 }).map(id), in testLazy()
65 …yOperator<Stream<Integer>>) s -> s.parallel().map(id).peek(e -> { counter.incrementAndGet(); }).ma… in testLazy()
100 Function<Integer, Integer> id = LambdaTestHelpers.identity(); in testMixedSeqPar() local
111 (UnaryOperator<Stream<Integer>>) s -> s.map(id), in testMixedSeqPar()
113 … (UnaryOperator<Stream<Integer>>) s -> s.map(id).sorted(Comparator.naturalOrder()).map(id), in testMixedSeqPar()
114 …Stream<Integer>>) s -> s.filter(LambdaTestHelpers.pEven).sorted(Comparator.naturalOrder()).map(id), in testMixedSeqPar()
/libcore/ojluni/src/main/java/sun/util/locale/
DLocaleExtensions.java50 private final String id; field in LocaleExtensions
62 private LocaleExtensions(String id, Character key, Extension value) { in LocaleExtensions() argument
63 this.id = id; in LocaleExtensions()
78 id = ""; in LocaleExtensions()
128 id = ""; in LocaleExtensions()
131 id = toID(map); in LocaleExtensions()
220 return id; in toString()
224 return id; in getID()
229 return id.hashCode(); in hashCode()
240 return id.equals(((LocaleExtensions)other).id); in equals()
DExtension.java37 private String value, id; field in Extension
50 this.id = key + LanguageTag.SEP + value; in setValue()
62 return id; in getID()
/libcore/luni/src/main/java/javax/xml/datatype/
DDatatypeConstants.java172 private final int id; field in DatatypeConstants.Field
179 private Field(final String str, final int id) { in Field() argument
181 this.id = id; in Field()
199 return id; in getId()
/libcore/ojluni/src/main/java/java/util/
DTimeZone.java566 public static synchronized TimeZone getTimeZone(String id) { in getTimeZone() argument
567 if (id == null) { in getTimeZone()
572 if (id.length() == 3) { in getTimeZone()
573 if (id.equals("GMT")) { in getTimeZone()
576 if (id.equals("UTC")) { in getTimeZone()
583 ZoneInfoData zoneInfoData = ZoneInfoDb.getInstance().makeZoneInfoData(id); in getTimeZone()
587 if (zone == null && id.length() > 3 && id.startsWith("GMT")) { in getTimeZone()
588 zone = getCustomTimeZone(id); in getTimeZone()
630 private static TimeZone getCustomTimeZone(String id) { in getCustomTimeZone() argument
631 Matcher m = NoImagePreloadHolder.CUSTOM_ZONE_ID_PATTERN.matcher(id); in getCustomTimeZone()
[all …]
/libcore/luni/src/test/java/libcore/java/util/
DOldLinkedHashMapTest.java36 String id = (String) iterator.next(); in testLinkedHashMap() local
37 map.get(id); in testLinkedHashMap()
52 id = (String) iterator.next(); in testLinkedHashMap()
53 mapClone.get(id); in testLinkedHashMap()
DTimeZoneTest.java161 for (String id : ids) { in testMinimalTransitionZones()
162 TimeZone tz = TimeZone.getTimeZone(id); in testMinimalTransitionZones()
275 for (String id : TimeZone.getAvailableIDs()) { in checkDisplayNames()
276 TimeZone tz = TimeZone.getTimeZone(id); in checkDisplayNames()
286 id, longDst, longStd)); in checkDisplayNames()
291 id, shortDst, shortStd)); in checkDisplayNames()
299 id, shortStd, longDst)); in checkDisplayNames()
303 id, longStd, shortDst)); in checkDisplayNames()
309 id, longDst, shortDst)); in checkDisplayNames()
318 failures.append(String.format("\n%s: LD %s", id, longDst)); in checkDisplayNames()
[all …]
/libcore/ojluni/src/test/java/time/tck/java/time/serial/
DTCKZoneIdSerialization.java105 String id = "QWERTYUIOPASDFGHJKLZXCVBNM~/._+-"; in test_deserialization_lenient_characters() local
106 ZoneId deser = deserialize(id); in test_deserialization_lenient_characters()
108 assertEquals(deser.getId(), id); in test_deserialization_lenient_characters() local
109 assertEquals(deser.toString(), id); in test_deserialization_lenient_characters() local
157 private ZoneId deserialize(String id) throws Exception { in deserialize() argument
174 …dos.writeByte(1 + 2 + id.length()); // length of data (1 byte + 2 bytes UTF length + 32 bytes UTF) in deserialize()
176 dos.writeUTF(id); in deserialize()
/libcore/luni/src/test/java/libcore/java/time/chrono/
DChronologyTest.java74 private final String id; field in ChronologyTest.FakeChronology
78 public FakeChronology(String id, String type) { in FakeChronology() argument
79 this.id = id; in FakeChronology()
86 return id; in getId()
/libcore/ojluni/annotations/hiddenapi/sun/security/x509/
DUniqueIdentity.java31 public UniqueIdentity(sun.security.util.BitArray id) { in UniqueIdentity() argument
35 public UniqueIdentity(byte[] id) { in UniqueIdentity() argument
62 private sun.security.util.BitArray id; field in UniqueIdentity

1234