/libcore/ojluni/src/test/java/time/test/java/time/ |
D | TestOffsetDateTime.java | 125 …OffsetDateTime base = OffsetDateTime.of(LocalDate.of(2008, 6, 30), LocalTime.of(11, 30, 59), OFFSE… in test_withOffsetSameLocal() local 126 OffsetDateTime test = base.withOffsetSameLocal(OFFSET_PTWO); in test_withOffsetSameLocal() 127 assertSame(test.toLocalDateTime(), base.toLocalDateTime()); in test_withOffsetSameLocal() 133 …OffsetDateTime base = OffsetDateTime.of(LocalDate.of(2008, 6, 30), LocalTime.of(11, 30, 59), OFFSE… in test_withOffsetSameLocal_noChange() local 134 OffsetDateTime test = base.withOffsetSameLocal(OFFSET_PONE); in test_withOffsetSameLocal_noChange() 135 assertSame(test, base); in test_withOffsetSameLocal_noChange() 140 …OffsetDateTime base = OffsetDateTime.of(LocalDate.of(2008, 6, 30), LocalTime.of(11, 30, 59), OFFSE… in test_withOffsetSameInstant_noChange() local 141 OffsetDateTime test = base.withOffsetSameInstant(OFFSET_PONE); in test_withOffsetSameInstant_noChange() 142 assertSame(test, base); in test_withOffsetSameInstant_noChange() 147 …OffsetDateTime base = OffsetDateTime.of(LocalDate.of(2008, 6, 30), LocalTime.of(11, 30, 59), OFFSE… in test_withYear_noChange() local [all …]
|
/libcore/luni/src/test/java/libcore/java/net/ |
D | URITest.java | 302 URI base = new URI("http://host/file?query/x"); in testRelativePathOnQuery() local 303 URI uri = base.resolve("another"); in testRelativePathOnQuery() 311 URI base = new URI("http://host/file?query/x#fragment"); in testRelativeFragmentOnQuery() local 312 URI uri = base.resolve("#another"); in testRelativeFragmentOnQuery() 325 URI base = new URI("http://host/file"); in testRelativePathAndFragment() local 326 assertEquals("http://host/another#fragment", base.resolve("another#fragment").toString()); in testRelativePathAndFragment() 330 URI base = new URI("http://host/a/b/c"); in testRelativeParentDirectory() local 331 assertEquals("http://host/a/d", base.resolve("../d").toString()); in testRelativeParentDirectory() 335 URI base = new URI("http://host/a/b/c"); in testRelativeChildDirectory() local 336 assertEquals("http://host/a/b/d/e", base.resolve("d/e").toString()); in testRelativeChildDirectory() [all …]
|
D | URLTest.java | 561 URL base = new URL("http://host/file?query/x"); in testRelativePathOnQuery() local 562 URL url = new URL(base, "another"); in testRelativePathOnQuery() 571 URL base = new URL("http://host/file?query/x#fragment"); in testRelativeFragmentOnQuery() local 572 URL url = new URL(base, "#another"); in testRelativeFragmentOnQuery() 606 URL base = new URL("http://host/file"); in testRelativePathAndFragment() local 607 assertEquals("http://host/another#fragment", new URL(base, "another#fragment").toString()); in testRelativePathAndFragment() 611 URL base = new URL("http://host/a/b/c"); in testRelativeParentDirectory() local 612 assertEquals("http://host/a/d", new URL(base, "../d").toString()); in testRelativeParentDirectory() 616 URL base = new URL("http://host/a/b/c"); in testRelativeChildDirectory() local 617 assertEquals("http://host/a/b/d/e", new URL(base, "d/e").toString()); in testRelativeChildDirectory() [all …]
|
D | OldAndroidURITest.java | 44 private static void resolve(String base, String uri, String expected) { in resolve() argument 45 URI b = URI.create(base); in resolve()
|
/libcore/ojluni/src/test/java/time/tck/java/time/ |
D | TCKZonedDateTime.java | 323 ZonedDateTime base = ZonedDateTime.of(LocalDateTime.of(1970, 1, 1, 12, 0), ZoneOffset.UTC); 326 Clock clock = Clock.fixed(base.toInstant(), offset); 393 LocalDateTime base = LocalDateTime.of(2008, 6, 30, 11, 30, 10, 500); 394 ZonedDateTime test = ZonedDateTime.of(base, ZONE_PARIS); 417 LocalDateTime base = LocalDateTime.of(2008, 6, 30, 11, 30, 10, 500); 418 ZonedDateTime.of(base, null); 1006 …ZonedDateTime base = ZonedDateTime.ofStrict(TEST_LOCAL_2008_06_30_11_30_59_500, OFFSET_0200, ZONE_… 1007 ZonedDateTime test = base.withEarlierOffsetAtOverlap(); 1008 assertEquals(test, base); // not changed 1013 …ZonedDateTime base = ZonedDateTime.ofStrict(TEST_PARIS_OVERLAP_2008_10_26_02_30, OFFSET_0100, ZONE… [all …]
|
D | TCKOffsetTime.java | 251 Instant base = LocalDateTime.of(1970, 1, 1, 12, 0).toInstant(ZoneOffset.UTC); 254 Clock clock = Clock.fixed(base, offset); 384 ZonedDateTime base = LocalDateTime.of(2007, 7, 15, 11, 30, 59, 500).atZone(OFFSET_PONE); 385 assertEquals(OffsetTime.from(base), TEST_11_30_59_500_PONE); 643 OffsetTime base = OffsetTime.of(11, 30, 59, 0, OFFSET_PONE); 644 OffsetTime test = base.withOffsetSameLocal(OFFSET_PTWO); 645 assertEquals(test.toLocalTime(), base.toLocalTime()); 651 OffsetTime base = OffsetTime.of(11, 30, 59, 0, OFFSET_PONE); 652 OffsetTime test = base.withOffsetSameLocal(OFFSET_PONE); 653 assertEquals(test, base); [all …]
|
D | TCKOffsetDateTime.java | 309 OffsetDateTime base = OffsetDateTime.of(1970, 1, 1, 12, 0, 0, 0, ZoneOffset.UTC); 312 Clock clock = Clock.fixed(base.toInstant(), offset); 772 …OffsetDateTime base = OffsetDateTime.of(LocalDate.of(2008, 6, 30), LocalTime.of(11, 30, 59), OFFSE… 773 base.withOffsetSameLocal(null); 781 …OffsetDateTime base = OffsetDateTime.of(LocalDate.of(2008, 6, 30), LocalTime.of(11, 30, 59), OFFSE… 782 OffsetDateTime test = base.withOffsetSameInstant(OFFSET_PTWO); 789 …OffsetDateTime base = OffsetDateTime.of(LocalDate.of(2008, 6, 30), LocalTime.of(11, 30, 59), OFFSE… 790 base.withOffsetSameInstant(null); 813 …public void test_with_fieldLong(OffsetDateTime base, TemporalField setField, long setValue, Offset… 814 assertEquals(base.with(setField, setValue), expected); [all …]
|
/libcore/ojluni/src/test/java/time/tck/java/time/format/ |
D | TCKDecimalStyle.java | 107 DecimalStyle base = DecimalStyle.STANDARD; in test_zeroDigit() local 108 assertEquals(base.withZeroDigit('A').getZeroDigit(), 'A'); in test_zeroDigit() 113 DecimalStyle base = DecimalStyle.STANDARD; in test_positiveSign() local 114 assertEquals(base.withPositiveSign('A').getPositiveSign(), 'A'); in test_positiveSign() 119 DecimalStyle base = DecimalStyle.STANDARD; in test_negativeSign() local 120 assertEquals(base.withNegativeSign('A').getNegativeSign(), 'A'); in test_negativeSign() 125 DecimalStyle base = DecimalStyle.STANDARD; in test_decimalSeparator() local 126 assertEquals(base.withDecimalSeparator('A').getDecimalSeparator(), 'A'); in test_decimalSeparator() 201 DecimalStyle base = DecimalStyle.STANDARD; in test_toString_base() local 202 assertEquals(base.toString(), "DecimalStyle[0+-.]"); in test_toString_base() [all …]
|
/libcore/luni/src/test/java/libcore/java/io/ |
D | FileTest.java | 41 String base = System.getProperty("java.io.tmpdir"); in createTemporaryDirectory() local 42 File directory = new File(base, UUID.randomUUID().toString()); in createTemporaryDirectory() 55 private static File createDeepStructure(File base) throws Exception { in createDeepStructure() argument 61 File f = base; in createDeepStructure() 72 File base = createTemporaryDirectory(); in test_longPath() local 73 assertTrue(createDeepStructure(base).exists()); in test_longPath() 84 File base = createTemporaryDirectory(); in test_longReadlink() local 85 File target = createDeepStructure(base); in test_longReadlink() 86 File source = new File(base, "source"); in test_longReadlink() 172 File base = createTemporaryDirectory(); in test_getCanonicalPath() local [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/ |
D | FileTest.java | 360 String base = tempDirectory.getPath(); in test_createNewFile() local 363 File dir = new File(base, String.valueOf(numDir)); in test_createNewFile() 370 dir = new File(base, String.valueOf(numDir)); in test_createNewFile() 531 String base = System.getProperty("java.io.tmpdir"); in test_createTempFileLjava_lang_StringLjava_lang_StringLjava_io_File() local 536 File dir = new File(base); in test_createTempFileLjava_lang_StringLjava_lang_StringLjava_io_File() 544 base = addTrailingSlash(base); in test_createTempFileLjava_lang_StringLjava_lang_StringLjava_io_File() 547 base, fileLocation); in test_createTempFileLjava_lang_StringLjava_lang_StringLjava_io_File() 561 dir = new File(base, String.valueOf(dirNumber)); in test_createTempFileLjava_lang_StringLjava_lang_StringLjava_io_File() 569 dir = new File(base, String.valueOf(dirNumber)); in test_createTempFileLjava_lang_StringLjava_lang_StringLjava_io_File() 706 String base = addTrailingSlash(tempDirectory.getPath()); in test_getAbsoluteFile() local [all …]
|
/libcore/ojluni/src/main/java/java/util/concurrent/atomic/ |
D | LongAccumulator.java | 96 base = this.identity = identity; in LongAccumulator() 107 (r = function.applyAsLong(b = base, x)) != b && !casBase(b, r)) { in accumulate() 129 long result = base; in get() 148 base = identity; in reset() 168 long result = base; in getThenReset() 169 base = identity; in getThenReset() 266 a.base = value; in readResolve()
|
D | LongAdder.java | 87 if ((as = cells) != null || !casBase(b = base, b + x)) { in add() 121 long sum = base; in sum() 139 base = 0L; in reset() 159 long sum = base; in sumThenReset() 160 base = 0L; in sumThenReset() 240 a.base = value; in readResolve()
|
D | DoubleAccumulator.java | 94 base = this.identity = Double.doubleToRawLongBits(identity); in DoubleAccumulator() 107 (Double.longBitsToDouble(b = base), x))) != b && !casBase(b, r)) { in accumulate() 131 double result = Double.longBitsToDouble(base); in get() 151 base = identity; in reset() 171 double result = Double.longBitsToDouble(base); in getThenReset() 172 base = identity; in getThenReset() 272 a.base = Double.doubleToRawLongBits(value); in readResolve()
|
D | DoubleAdder.java | 92 !casBase(b = base, in add() 119 double sum = Double.longBitsToDouble(base); in sum() 137 base = 0L; // relies on fact that double 0 must have same rep as long in reset() 157 double sum = Double.longBitsToDouble(base); in sumThenReset() 158 base = 0L; in sumThenReset() 239 a.base = Double.doubleToRawLongBits(value); in readResolve()
|
/libcore/benchmarks/src/benchmarks/ |
D | BigIntegerBenchmark.java | 124 private static BigInteger myPow(BigInteger base, int exp, BigInteger scaleBy) { in myPow() argument 128 BigInteger tmp = myPow(base, exp - 1, scaleBy); in myPow() 129 return tmp.multiply(base).divide(scaleBy); in myPow() 131 BigInteger tmp = myPow(base, exp / 2, scaleBy); in myPow() 141 BigInteger base = scaledOne.add(scaledOne.divide(BigInteger.valueOf(n))); in eApprox() local 142 return myPow(base, n, scaledOne); in eApprox() 169 BigInteger base = BigInteger.TEN.pow(len / 4); in repeatModPow() local 173 BigInteger newRes = base.modPow(exponent, product); in repeatModPow() 180 if (!lastRes.mod(odd1).equals(base.modPow(exponent, odd1))) { in repeatModPow() 183 + "base.modPow(exponent, odd1)=" + base.modPow(exponent, odd1) + " base=" in repeatModPow() [all …]
|
/libcore/ojluni/src/main/java/java/awt/font/ |
D | NumericShaper.java | 346 private final int base; field in NumericShaper.Range 351 private Range(int base, int start, int end) { in Range() argument 352 this.base = base - ('0' + getNumericBase()); in Range() 358 return base; in getDigitBase() 1082 return s1.base > s2.base ? 1 : s1.base == s2.base ? 0 : -1; in NumericShaper() 1245 int base; in shapeNonContextually() local 1248 base = shapingRange.getDigitBase(); in shapeNonContextually() 1251 base = bases[key]; in shapeNonContextually() 1259 text[i] = (char)(c + base); in shapeNonContextually() 1276 int base = bases[ctxKey]; in shapeContextually() local [all …]
|
/libcore/ojluni/src/main/java/sun/security/provider/certpath/ |
D | Builder.java | 143 static int distance(GeneralNameInterface base, in distance() argument 146 switch (base.constrains(test)) { in distance() 169 return test.subtreeDepth() - base.subtreeDepth(); in distance() 189 static int hops(GeneralNameInterface base, GeneralNameInterface test, in hops() argument 192 int baseRtest = base.constrains(test); in hops() 207 return (test.subtreeDepth()-base.subtreeDepth()); in hops() 210 return (test.subtreeDepth()-base.subtreeDepth()); in hops() 216 if (base.getType() != GeneralNameInterface.NAME_DIRECTORY) { in hops() 223 X500Name baseName = (X500Name)base; in hops()
|
/libcore/ojluni/src/main/java/java/util/ |
D | ArraysParallelSortHelpers.java | 116 final int base, size, wbase, gran; field in ArraysParallelSortHelpers.FJObject.Sorter 118 Sorter(CountedCompleter<?> par, T[] a, T[] w, int base, int size, in Sorter() argument 122 this.a = a; this.w = w; this.base = base; this.size = size; in Sorter() 130 int b = this.base, n = this.size, wb = this.wbase, g = this.gran; in compute() 238 final int base, size, wbase, gran; field in ArraysParallelSortHelpers.FJByte.Sorter 239 Sorter(CountedCompleter<?> par, byte[] a, byte[] w, int base, in Sorter() argument 242 this.a = a; this.w = w; this.base = base; this.size = size; in Sorter() 248 int b = this.base, n = this.size, wb = this.wbase, g = this.gran; in compute() 349 final int base, size, wbase, gran; field in ArraysParallelSortHelpers.FJChar.Sorter 350 Sorter(CountedCompleter<?> par, char[] a, char[] w, int base, in Sorter() argument [all …]
|
D | ComparableTimSort.java | 504 int base, int len, int hint) { in gallopLeft() argument 509 if (key.compareTo(a[base + hint]) > 0) { in gallopLeft() 512 while (ofs < maxOfs && key.compareTo(a[base + hint + ofs]) > 0) { in gallopLeft() 527 while (ofs < maxOfs && key.compareTo(a[base + hint - ofs]) <= 0) { in gallopLeft() 552 if (key.compareTo(a[base + m]) > 0) in gallopLeft() 574 int base, int len, int hint) { in gallopRight() argument 579 if (key.compareTo(a[base + hint]) < 0) { in gallopRight() 582 while (ofs < maxOfs && key.compareTo(a[base + hint - ofs]) < 0) { in gallopRight() 598 while (ofs < maxOfs && key.compareTo(a[base + hint + ofs]) >= 0) { in gallopRight() 622 if (key.compareTo(a[base + m]) < 0) in gallopRight()
|
/libcore/ojluni/src/main/java/java/util/concurrent/ |
D | ForkJoinPool.java | 817 volatile int base; // index of next slot for poll field in ForkJoinPool.WorkQueue 833 base = top = INITIAL_QUEUE_CAPACITY >>> 1; in WorkQueue() 847 int n = base - top; // read base first in queueSize() 858 return ((n = base - (s = top)) >= 0 || // possibly one task in isEmpty() 877 if ((d = base - s) == 0 && p != null) { in push() 899 (t = top) - (b = base) > 0) { in growArray() 920 int b = base, s = top, al, i; ForkJoinTask<?>[] a; in pop() 947 if (t != null && b++ == base && in pollAt() 949 base = b; in pollAt() 961 int b = base, s = top, d, al; ForkJoinTask<?>[] a; in poll() [all …]
|
/libcore/ojluni/src/main/java/java/net/ |
D | URI.java | 2002 private static String resolvePath(String base, String child, in resolvePath() argument 2005 int i = base.lastIndexOf('/'); in resolvePath() 2012 path = base.substring(0, i + 1); in resolvePath() 2014 StringBuffer sb = new StringBuffer(base.length() + cn); in resolvePath() 2017 sb.append(base.substring(0, i + 1)); in resolvePath() 2035 private static URI resolve(URI base, URI child) { in resolve() argument 2038 if (child.isOpaque() || base.isOpaque()) in resolve() 2045 if ((base.fragment != null) in resolve() 2046 && child.fragment.equals(base.fragment)) { in resolve() 2047 return base; in resolve() [all …]
|
/libcore/test-rules/src/main/java/libcore/junit/util/ |
D | ResourceLeakageDetector.java | 135 public Statement apply(Statement base, Description description) { in apply() argument 140 return base; in apply() 143 return leakageDetectorRule.apply(base, description); in apply()
|
/libcore/ojluni/src/main/java/sun/nio/ch/ |
D | IOVecWrapper.java | 141 void putBase(int i, long base) { in putBase() argument 144 vecArray.putInt(offset, (int)base); in putBase() 146 vecArray.putLong(offset, base); in putBase()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/math/ |
D | BigIntegerModPowTest.java | 106 …BigInteger[] base = new BigInteger[] {new BigInteger("-1"), new BigInteger("0"), new BigInteger("1… in testModPowZeroExp() local 109 for (int i = 0; i < base.length; ++i) { in testModPowZeroExp() 111 assertEquals(base[i] + " modePow(" + exp + ", " + mod[j] in testModPowZeroExp() 113 base[i].modPow(exp, mod[j])); in testModPowZeroExp() 118 for (int i = 0; i < base.length; ++i) { in testModPowZeroExp() 120 assertEquals(base[i] + " modePow(" + exp + ", " + mod[j] in testModPowZeroExp() 122 base[i].modPow(exp, mod[j])); in testModPowZeroExp()
|
/libcore/ojluni/src/test/java/time/tck/java/time/temporal/ |
D | TCKChronoUnit.java | 169 …public void test_unitAndTemporal(ChronoUnit unit, Temporal base, boolean isSupportedBy, long amoun… in test_unitAndTemporal() argument 170 assertEquals(unit.isSupportedBy(base), isSupportedBy); in test_unitAndTemporal() 172 Temporal result = unit.addTo(base, amount); in test_unitAndTemporal() 174 assertEquals(unit.between(base, result), amount); in test_unitAndTemporal()
|