Home
last modified time | relevance | path

Searched refs:secs (Results 1 – 8 of 8) sorted by relevance

/libcore/ojluni/src/main/java/java/nio/file/attribute/
DFileTime.java146 long secs = unit.convert(instant.getEpochSecond(), TimeUnit.SECONDS); in to() local
147 if (secs == Long.MIN_VALUE || secs == Long.MAX_VALUE) { in to()
148 return secs; in to()
151 long r = secs + nanos; in to()
153 if (((secs ^ r) & (nanos ^ r)) < 0) { in to()
154 return (secs < 0) ? Long.MIN_VALUE : Long.MAX_VALUE; in to()
173 long secs = instant.getEpochSecond(); in toMillis() local
176 long r = secs * 1000; in toMillis()
177 long ax = Math.abs(secs); in toMillis()
179 if ((r / 1000) != secs) { in toMillis()
[all …]
/libcore/ojluni/src/main/java/java/time/
DDuration.java241 long secs = Math.addExact(seconds, Math.floorDiv(nanoAdjustment, NANOS_PER_SECOND)); in ofSeconds() local
243 return create(secs, nos); in ofSeconds()
256 long secs = millis / 1000; in ofMillis() local
260 secs--; in ofMillis()
262 return create(secs, mos * 1000_000); in ofMillis()
275 long secs = nanos / NANOS_PER_SECOND; in ofNanos() local
279 secs--; in ofNanos()
281 return create(secs, nos); in ofNanos()
437 … create(boolean negate, long daysAsSecs, long hoursAsSecs, long minsAsSecs, long secs, int nanos) { in create() argument
438 …g seconds = Math.addExact(daysAsSecs, Math.addExact(hoursAsSecs, Math.addExact(minsAsSecs, secs))); in create()
[all …]
DInstant.java322 long secs = Math.addExact(epochSecond, Math.floorDiv(nanoAdjustment, NANOS_PER_SECOND)); in ofEpochSecond() local
324 return create(secs, nos); in ofEpochSecond()
338 long secs = Math.floorDiv(epochMilli, 1000); in ofEpochMilli() local
340 return create(secs, mos * 1000_000); in ofEpochMilli()
DLocalTime.java1507 long secs = epochDay * 86400 + toSecondOfDay(); in toEpochSecond() local
1508 secs -= offset.getTotalSeconds(); in toEpochSecond()
1509 return secs; in toEpochSecond()
/libcore/ojluni/src/main/java/java/time/chrono/
DChronoLocalDateTime.java466 long secs = epochDay * 86400 + toLocalTime().toSecondOfDay(); in toEpochSecond() local
467 secs -= offset.getTotalSeconds(); in toEpochSecond()
468 return secs; in toEpochSecond()
DChronoZonedDateTime.java547 long secs = epochDay * 86400 + toLocalTime().toSecondOfDay(); in toEpochSecond() local
548 secs -= getOffset().getTotalSeconds(); in toEpochSecond()
549 return secs; in toEpochSecond()
/libcore/ojluni/annotations/hiddenapi/java/time/
DDuration.java135 long secs, in create() argument
/libcore/ojluni/src/test/java/time/tck/java/time/
DTCKLocalTime.java2171 int secs = (int) (Long.MAX_VALUE % (24L * 60L * 60L));
2172 assertEquals(t, LocalTime.of(2, 30).minusSeconds(secs));