Home
last modified time | relevance | path

Searched refs:convert (Results 1 – 14 of 14) sorted by relevance

/libcore/jsr166-tests/src/test/java/jsr166/
DTimeUnitTest.java44 SECONDS.convert(t, DAYS)); in testConvert()
46 SECONDS.convert(t, HOURS)); in testConvert()
48 SECONDS.convert(t, MINUTES)); in testConvert()
50 SECONDS.convert(t, SECONDS)); in testConvert()
52 SECONDS.convert(1000L*t, MILLISECONDS)); in testConvert()
54 SECONDS.convert(1000000L*t, MICROSECONDS)); in testConvert()
56 SECONDS.convert(1000000000L*t, NANOSECONDS)); in testConvert()
59 MILLISECONDS.convert(t, DAYS)); in testConvert()
61 MILLISECONDS.convert(t, HOURS)); in testConvert()
63 MILLISECONDS.convert(t, MINUTES)); in testConvert()
[all …]
DDelayQueueTest.java123 return unit.convert(n, TimeUnit.NANOSECONDS); in getDelay()
/libcore/ojluni/src/main/java/java/util/concurrent/
DTimeUnit.java85 public long convert(long d, TimeUnit u) { return u.toNanos(d); } in convert() method
100 public long convert(long d, TimeUnit u) { return u.toMicros(d); } in convert() method
115 public long convert(long d, TimeUnit u) { return u.toMillis(d); } in convert() method
130 public long convert(long d, TimeUnit u) { return u.toSeconds(d); } in convert() method
146 public long convert(long d, TimeUnit u) { return u.toMinutes(d); } in convert() method
162 public long convert(long d, TimeUnit u) { return u.toHours(d); } in convert() method
178 public long convert(long d, TimeUnit u) { return u.toDays(d); } in convert() method
226 public long convert(long sourceDuration, TimeUnit sourceUnit) { in convert() method in TimeUnit
DScheduledThreadPoolExecutor.java241 return unit.convert(time - System.nanoTime(), NANOSECONDS); in getDelay()
DThreadPoolExecutor.java1751 return unit.convert(keepAliveTime, TimeUnit.NANOSECONDS); in getKeepAliveTime()
/libcore/ojluni/src/test/java/nio/file/attribute/
DFileTimeTest.java50 long tomorrowInDays = TimeUnit.DAYS.convert(now, MILLISECONDS) + 1; in main()
51 long yesterdayInDays = TimeUnit.DAYS.convert(now, MILLISECONDS) - 1; in main()
107 to(MILLISECONDS.convert(1, DAYS) - 1, MILLISECONDS); in main()
108 to(MILLISECONDS.convert(1, DAYS) + 0, MILLISECONDS); in main()
109 to(MILLISECONDS.convert(1, DAYS) + 1, MILLISECONDS); in main()
113 to(MILLISECONDS.convert(-1, DAYS) - 1, MILLISECONDS); in main()
114 to(MILLISECONDS.convert(-1, DAYS) + 0, MILLISECONDS); in main()
115 to(MILLISECONDS.convert(-1, DAYS) + 1, MILLISECONDS); in main()
296 long secs = SECONDS.convert(value, unit); in eqTime()
297 long nanos = NANOSECONDS.convert(value - unit.convert(secs, SECONDS), unit); in eqTime()
[all …]
/libcore/ojluni/src/main/java/java/nio/file/attribute/
DFileTime.java144 return unit.convert(this.value, this.unit); in to()
146 long secs = unit.convert(instant.getEpochSecond(), TimeUnit.SECONDS); in to()
150 long nanos = unit.convert(instant.getNano(), TimeUnit.NANOSECONDS); in to()
318 return unit.toNanos(value - unit.convert(days, TimeUnit.DAYS)); in toExcessNanos()
/libcore/ojluni/src/main/java/sun/invoke/util/
DWrapper.java231 public <T> T zero(Class<T> type) { return convert(zero, type); } in zero()
439 return convert(x, type, true); in cast()
447 public <T> T convert(Object x, Class<T> type) { in convert() method in Wrapper
448 return convert(x, type, false); in convert()
451 private <T> T convert(Object x, Class<T> type, boolean isCast) { in convert() method in Wrapper
592 value = convert(value, primitiveType); in copyArrayUnboxing()
/libcore/ojluni/annotations/hiddenapi/sun/security/util/
DDerIndefLenConverter.java92 byte[] convert(byte[] indefData) throws java.io.IOException { in convert() method in DerIndefLenConverter
/libcore/ojluni/src/main/java/sun/security/util/
DDerInputStream.java135 buffer = new DerInputBuffer(derIn.convert(inData)); in init()
440 buffer = new DerInputBuffer(derIn.convert(indefData)); in readVector()
DDerValue.java275 inbuf = new DerInputBuffer(derIn.convert(indefData)); in DerValue()
393 in = new ByteArrayInputStream(derIn.convert(indefData)); in init()
DDerIndefLenConverter.java320 byte[] convert(byte[] indefData) throws IOException { in convert() method in DerIndefLenConverter
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
DArraysTest.java1883 Object convertedGolden = converter.convert(golden); in test_sort()
1884 Object convertedTest = converter.convert(test); in test_sort()
2221 Object convert(int[] a) { in convert() method
2227 Object convert(int[] a) { in convert() method
2238 Object convert(int[] a) { in convert() method
2249 Object convert(int[] a) { in convert() method
2260 Object convert(int[] a) { in convert() method
2271 Object convert(int[] a) { in convert() method
2282 Object convert(int[] a) { in convert() method
2292 abstract Object convert(int[] a); in convert() method in ArraysTest.PrimitiveTypeConverter
/libcore/ojluni/src/main/java/java/lang/invoke/
DMethodHandles.java2736 value = w.convert(value, type); in constant()
2822 values[i] = Wrapper.forPrimitiveType(ptype).convert(values[i], ptype); in insertArguments()